diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2020-11-10 10:38:34 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2020-11-10 10:38:34 +0800 |
commit | 63896ba92a934bdb6a4952882f486d1389a92a67 (patch) | |
tree | 687c6c807dacbfae54ea9a21a0cf984227cc8a7f /test-beta | |
parent | 86f40ba0cbdb6ef0762e7b7bd681568f83d312e7 (diff) | |
download | lua-language-server-63896ba92a934bdb6a4952882f486d1389a92a67.zip |
#244 向前搜索赋值不受搜索深度影响,经测试该功能对性能影响很小
Diffstat (limited to 'test-beta')
-rw-r--r-- | test-beta/crossfile/definition.lua | 32 | ||||
-rw-r--r-- | test-beta/crossfile/hover.lua | 7 |
2 files changed, 33 insertions, 6 deletions
diff --git a/test-beta/crossfile/definition.lua b/test-beta/crossfile/definition.lua index 743325c2..5bc99a19 100644 --- a/test-beta/crossfile/definition.lua +++ b/test-beta/crossfile/definition.lua @@ -1,6 +1,7 @@ -local files = require 'files' -local furi = require 'file-uri' -local core = require 'core.definition' +local files = require 'files' +local furi = require 'file-uri' +local core = require 'core.definition' +local config = require 'config' rawset(_G, 'TEST', true) @@ -558,6 +559,31 @@ TEST { }, } +config.config.intelliSense.searchDepth = 0 + +TEST { + { + path = 'a.lua', + content = [[ + local t = GlobalTable + + t.settings = { + <!test!> = 1 + } + ]], + }, + { + path = 'b.lua', + content = [[ + local b = GlobalTable.settings + + print(b.<?test?>) + ]] + }, +} + +config.config.intelliSense.searchDepth = 5 + TEST { { path = 'a.lua', diff --git a/test-beta/crossfile/hover.lua b/test-beta/crossfile/hover.lua index 8cd5eada..a049a66a 100644 --- a/test-beta/crossfile/hover.lua +++ b/test-beta/crossfile/hover.lua @@ -1,6 +1,7 @@ -local files = require 'files' -local furi = require 'file-uri' -local core = require 'core.hover' +local files = require 'files' +local furi = require 'file-uri' +local core = require 'core.hover' +local config = require 'config' rawset(_G, 'TEST', true) |