File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -114,6 +114,7 @@ Return the signatures of all methods whose definition spans the specified locati
114114Returns `nothing` if there are no methods at that location.
115115"""
116116function signatures_at(filename:: AbstractString , line:: Integer )
117+ filename = abspath(filename)
117118 if occursin(juliabase, filename)
118119 rpath = postpath(filename, juliabase)
119120 id = PkgId(Base)
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ using CodeTracking
44using Test, InteractiveUtils
55# Note: ColorTypes needs to be installed, but note the intentional absence of `using ColorTypes`
66
7- include(" script.jl" )
7+ isdefined(Main, :Revise) ? includet( " script.jl " ) : include(" script.jl" )
88
99@testset " CodeTracking.jl" begin
1010 m = first(methods(f1))
8787 @test ! isempty(sigs)
8888 sigs = signatures_at(Base. find_source_file(String(m. file)), m. line)
8989 @test ! isempty(sigs)
90+
91+ # issue #23
92+ @test ! isempty(signatures_at(" script.jl" , 9 ))
9093 end
9194end
You can’t perform that action at this time.
0 commit comments