summaryrefslogtreecommitdiff
path: root/server/test/crossfile/definition.lua
diff options
context:
space:
mode:
authorsumneko <sumneko@hotmail.com>2019-04-22 17:47:01 +0800
committersumneko <sumneko@hotmail.com>2019-04-22 17:47:01 +0800
commit57eefd5142fab69c1e575917945fd3aded42f5ca (patch)
tree1b1b0f0ed1503bf3b68d800318f486bc0523210d /server/test/crossfile/definition.lua
parentea693e88c314ed118dab0121524453b1ba3bea90 (diff)
downloadlua-language-server-57eefd5142fab69c1e575917945fd3aded42f5ca.zip
查找引用也通过转到定义实现
Diffstat (limited to 'server/test/crossfile/definition.lua')
-rw-r--r--server/test/crossfile/definition.lua3
1 files changed, 1 insertions, 2 deletions
diff --git a/server/test/crossfile/definition.lua b/server/test/crossfile/definition.lua
index 4e3a00ef..f49530ea 100644
--- a/server/test/crossfile/definition.lua
+++ b/server/test/crossfile/definition.lua
@@ -89,8 +89,7 @@ function TEST(datas)
local sourceVM = lsp:getVM(sourceUri)
assert(sourceVM)
local sourcePos = (sourceList[1][1] + sourceList[1][2]) // 2
- local source = core.findSource(sourceVM, sourcePos)
- local positions = core.definition(sourceVM, source, lsp)
+ local positions = core.definition(sourceVM, sourcePos, 'definition', lsp)
if positions then
assert(founded(targetList, positions))
else