diff options
author | sumneko <sumneko@hotmail.com> | 2019-04-28 21:23:33 +0800 |
---|---|---|
committer | sumneko <sumneko@hotmail.com> | 2019-04-28 21:23:33 +0800 |
commit | 2793fe8003d10c5d7db54a63f3e6140ce305fb92 (patch) | |
tree | 5e460fa481c6c7649f439e70938d42b2354dce0c /server/test/crossfile/definition.lua | |
parent | ef4df9c2b854808e2fa1280e383c5e4213d66a28 (diff) | |
download | lua-language-server-2793fe8003d10c5d7db54a63f3e6140ce305fb92.zip |
definition会找到定义者自己
Diffstat (limited to 'server/test/crossfile/definition.lua')
-rw-r--r-- | server/test/crossfile/definition.lua | 23 |
1 files changed, 16 insertions, 7 deletions
diff --git a/server/test/crossfile/definition.lua b/server/test/crossfile/definition.lua index 06512f9b..9de93c92 100644 --- a/server/test/crossfile/definition.lua +++ b/server/test/crossfile/definition.lua @@ -117,6 +117,7 @@ TEST { { path = 'b.lua', content = 'local <?t?> = require "a"', + target = {7, 7}, }, } @@ -140,6 +141,7 @@ TEST { { path = 'b.lua', content = 'local <?t?> = require "a"', + target = {7, 7}, }, } @@ -209,6 +211,7 @@ TEST { content = [[ local <?t?> = require 'a' ]], + target = {19, 19}, }, } @@ -310,8 +313,9 @@ TEST { { path = 'b.lua', content = [[ - local <?t?> = require 'a' - ]] + local <!t!> = require 'a' + <?t?> + ]], } } @@ -331,7 +335,8 @@ TEST { { path = 'c.lua', content = [[ - local <?f?> = require 'a' + local <!f!> = require 'a' + <?f?> ]] } } @@ -354,7 +359,8 @@ TEST { { path = 'c.lua', content = [[ - local <?f?> = require 'a' + local <!f!> = require 'a' + <?f?> ]] } } @@ -369,7 +375,8 @@ TEST { { path = 'b/xxx.lua', content = [[ - local <?f?> = require 'xxx' + local <!f!> = require 'xxx' + <?f?> return function () end ]] } @@ -387,7 +394,8 @@ TEST { path = 'b.lua', content = [[ ---@type Class - local <?obj?> + local <!obj!> + <?obj?> ]] }, } @@ -397,7 +405,8 @@ TEST { path = 'a.lua', content = [[ ---@type Class - local <?obj?> + local <!obj!> + <?obj?> ]] }, { |