@@ -45,3 +45,33 @@ def test_implementation_intrinsics():
45
45
errcode , results = run_request (string , ["-n" , "1" ])
46
46
assert errcode == 0
47
47
assert results [1 ] is None
48
+
49
+
50
+ def test_implementation_integer ():
51
+ """Go to implementation when no implementation is present is handled gracefully"""
52
+ string = write_rpc_request (1 , "initialize" , {"rootPath" : str (test_dir / "rename" )})
53
+ file_path = test_dir / "rename" / "test_rename_intrinsic.f90"
54
+ string += imp_request (file_path , 20 , 31 )
55
+ errcode , results = run_request (string , ["-n" , "1" ])
56
+ assert errcode == 0
57
+ assert results [1 ] is None
58
+
59
+
60
+ def test_implementation_empty ():
61
+ """Go to implementation for empty lines is handled gracefully"""
62
+ string = write_rpc_request (1 , "initialize" , {"rootPath" : str (test_dir / "rename" )})
63
+ file_path = test_dir / "rename" / "test_rename_intrinsic.f90"
64
+ string += imp_request (file_path , 13 , 0 )
65
+ errcode , results = run_request (string , ["-n" , "1" ])
66
+ assert errcode == 0
67
+ assert results [1 ] is None
68
+
69
+
70
+ def test_implementation_no_file ():
71
+ """Go to implementation for empty lines is handled gracefully"""
72
+ string = write_rpc_request (1 , "initialize" , {"rootPath" : str (test_dir / "rename" )})
73
+ file_path = test_dir / "rename" / "fake.f90"
74
+ string += imp_request (file_path , 13 , 0 )
75
+ errcode , results = run_request (string , ["-n" , "1" ])
76
+ assert errcode == 0
77
+ assert results [1 ] is None
0 commit comments