summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/completion/common.lua34
1 files changed, 34 insertions, 0 deletions
diff --git a/test/completion/common.lua b/test/completion/common.lua
index dab31c31..b73543fb 100644
--- a/test/completion/common.lua
+++ b/test/completion/common.lua
@@ -3782,6 +3782,40 @@ f(<??>)
}
TEST [[
+local x = 1
+local y = 2
+
+---@enum Enum
+local t = {
+ x = x,
+ y = y,
+}
+
+---@param p Enum
+local function f(p) end
+
+f(<??>)
+]]
+{
+ {
+ label = 't.x',
+ kind = define.CompletionItemKind.EnumMember,
+ },
+ {
+ label = 't.y',
+ kind = define.CompletionItemKind.EnumMember,
+ },
+ {
+ label = '1',
+ kind = define.CompletionItemKind.EnumMember,
+ },
+ {
+ label = '2',
+ kind = define.CompletionItemKind.EnumMember,
+ },
+}
+
+TEST [[
--
<??>
]]