summaryrefslogtreecommitdiff
path: root/server/test
diff options
context:
space:
mode:
Diffstat (limited to 'server/test')
-rw-r--r--server/test/hover/init.lua36
1 files changed, 36 insertions, 0 deletions
diff --git a/server/test/hover/init.lua b/server/test/hover/init.lua
index ceaca791..17913039 100644
--- a/server/test/hover/init.lua
+++ b/server/test/hover/init.lua
@@ -257,3 +257,39 @@ TEST [[
(<?'xxx'?>):sub()
]]
(nil)
+
+TEST [[
+local <?t?> = {
+ a = 1,
+ b = 2,
+ c = 3,
+}
+]]
+[[
+local t: {
+ a: number = 1,
+ b: number = 2,
+ c: number = 3,
+}
+]]
+
+TEST [[
+local <?t?> = {
+ a = 1,
+ [1] = 2,
+ [true] = 3,
+ [5.5] = 4,
+ [{}] = 5,
+ [function () end] = 6,
+}
+]]
+[[
+local t: {
+ a: number = 1,
+ [1]: number = 2,
+ [true]: number = 3,
+ [5.5]: number = 4,
+ [*table]: number = 5,
+ [*function]: number = 6,
+}
+]]