diff options
Diffstat (limited to 'test/completion/init.lua')
-rw-r--r-- | test/completion/init.lua | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/test/completion/init.lua b/test/completion/init.lua index 69241afd..9c87ab33 100644 --- a/test/completion/init.lua +++ b/test/completion/init.lua @@ -2615,3 +2615,53 @@ f(fun$) kind = define.CompletionItemKind.Snippet, } } + +TEST [[ +---@type {[1]: number} +local t + +t.$ +]] +{ + { + label = '1', + kind = define.CompletionItemKind.Field, + textEdit = { + newText = '[1]', + start = 35, + finish = 34, + }, + additionalTextEdits = { + { + start = 34, + finish = 34, + newText = '', + }, + }, + } +} + +TEST [[ +---@type {[1]: number} +local t + +t.$ +]] +{ + { + label = '1', + kind = define.CompletionItemKind.Field, + textEdit = { + newText = '[1]', + start = 35, + finish = 34, + }, + additionalTextEdits = { + { + start = 34, + finish = 34, + newText = '', + }, + }, + } +} |