summaryrefslogtreecommitdiff
path: root/test/completion/init.lua
diff options
context:
space:
mode:
Diffstat (limited to 'test/completion/init.lua')
-rw-r--r--test/completion/init.lua27
1 files changed, 27 insertions, 0 deletions
diff --git a/test/completion/init.lua b/test/completion/init.lua
index ea1cdfdb..1ed82b2a 100644
--- a/test/completion/init.lua
+++ b/test/completion/init.lua
@@ -2696,3 +2696,30 @@ local r = f('$')
},
},
}
+
+TEST [[
+---@type fun(x: "'aaa'"|"'bbb'")
+local f
+
+f('$')
+]]
+{
+ {
+ label = "'aaa'",
+ kind = define.CompletionItemKind.EnumMember,
+ textEdit = {
+ newText = "'aaa'",
+ start = 45,
+ finish = 46,
+ },
+ },
+ {
+ label = "'bbb'",
+ kind = define.CompletionItemKind.EnumMember,
+ textEdit = {
+ newText = "'bbb'",
+ start = 45,
+ finish = 46,
+ },
+ },
+}