summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/crossfile/completion.lua27
1 files changed, 27 insertions, 0 deletions
diff --git a/test/crossfile/completion.lua b/test/crossfile/completion.lua
index 9c943d7d..8f3473ec 100644
--- a/test/crossfile/completion.lua
+++ b/test/crossfile/completion.lua
@@ -571,6 +571,33 @@ TEST {
}
end
+TEST {
+ {
+ path = 'a.lua',
+ content = [[
+ local t = {
+ x = 1,
+ }
+ return t
+ ]]
+ },
+ {
+ path = 'b.lua',
+ main = true,
+ content = [[
+ local t = require 'a'
+ local v = setmetatable({}, {__index = t})
+ v.$
+ ]]
+ },
+ completion = {
+ {
+ label = 'x',
+ kind = CompletionItemKind.Enum,
+ }
+ }
+}
+
Cared['description'] = true
TEST {
{