summaryrefslogtreecommitdiff
path: root/test/crossfile
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-01-05 16:46:08 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-01-05 16:46:08 +0800
commitc9b94234048a9608a732e85251757d02fcf19c8a (patch)
treedc95e70c233ab72e46e8bcb1fe7b9d8f6731886e /test/crossfile
parent2877f084943ba30a9970cbe9a5cb0be844a2ec64 (diff)
downloadlua-language-server-c9b94234048a9608a732e85251757d02fcf19c8a.zip
cleanup
Diffstat (limited to 'test/crossfile')
-rw-r--r--test/crossfile/diagnostic.lua18
1 files changed, 6 insertions, 12 deletions
diff --git a/test/crossfile/diagnostic.lua b/test/crossfile/diagnostic.lua
index ab2c3e41..0a32ddb0 100644
--- a/test/crossfile/diagnostic.lua
+++ b/test/crossfile/diagnostic.lua
@@ -53,24 +53,18 @@ function TEST(datas)
end
- local result = {}
+ local results = {}
for _, data in ipairs(datas) do
local uri = furi.encode(data.path)
- local results = {}
core(uri, function (result)
- for _, res in ipairs(result) do
- results[#results+1] = res
- end
- end)
- for i, position in ipairs(results) do
- result[i] = {
- position.start,
- position.finish,
+ results[#results+1] = {
+ result.start,
+ result.finish,
uri,
}
- end
+ end)
end
- assert(founded(targetList, result))
+ assert(founded(targetList, results))
end
TEST {