summaryrefslogtreecommitdiff
path: root/server/test
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2018-12-19 16:21:50 +0800
committer最萌小汐 <sumneko@hotmail.com>2018-12-19 16:21:50 +0800
commit712b8bfd2946e15d4550fbe662746acaad46a53a (patch)
tree1c0b3b40d7d1fd3b4d4b68cf856a28548c6bba58 /server/test
parent1f4ed24c48c9c48ffa4f2bddf64ef169839fc538 (diff)
downloadlua-language-server-712b8bfd2946e15d4550fbe662746acaad46a53a.zip
支持看表里的数据
Diffstat (limited to 'server/test')
-rw-r--r--server/test/completion/init.lua17
-rw-r--r--server/test/vm/dirty.lua7
2 files changed, 24 insertions, 0 deletions
diff --git a/server/test/completion/init.lua b/server/test/completion/init.lua
index 1524badf..c666dd5d 100644
--- a/server/test/completion/init.lua
+++ b/server/test/completion/init.lua
@@ -195,3 +195,20 @@ loc@
kind = CompletionItemKind.Keyword,
}
}
+
+TEST [[
+t.a = {}
+t.b = {}
+t.@
+]]
+{
+ {
+ label = 'a',
+ kind = CompletionItemKind.Field,
+ },
+ {
+ label = 'b',
+ kind = CompletionItemKind.Field,
+ },
+}
+
diff --git a/server/test/vm/dirty.lua b/server/test/vm/dirty.lua
index e69de29b..9c2e65fb 100644
--- a/server/test/vm/dirty.lua
+++ b/server/test/vm/dirty.lua
@@ -0,0 +1,7 @@
+TEST [[
+a.
+]]
+
+TEST [[
+a:
+]]