diff options
Diffstat (limited to 'test/crossfile/hover.lua')
-rw-r--r-- | test/crossfile/hover.lua | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/test/crossfile/hover.lua b/test/crossfile/hover.lua index d47bb41b..3cd560ff 100644 --- a/test/crossfile/hover.lua +++ b/test/crossfile/hover.lua @@ -176,6 +176,55 @@ end TEST { { path = 'a.lua', + content = '---@meta _', + }, + { + path = 'b.lua', + content = 'require <?"a"?>', + }, + hover = [[ +```lua +1 个字节 +```]], +} + +TEST { + { + path = 'a.lua', + content = '---@meta xxx', + }, + { + path = 'b.lua', + content = 'require <?"a"?>', + }, + hover = [[ +```lua +1 个字节 +```]], +} + +TEST { + { + path = 'a.lua', + content = '---@meta xxx', + }, + { + path = 'b.lua', + content = 'require <?"xxx"?>', + }, + hover = [=[ +```lua +3 个字节 +``` + +--- + +* [[meta]](file:///a.lua)]=], +} + +TEST { + { + path = 'a.lua', content = [[ local function f(a, b) end |