aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-12-29 23:16:52 -0500
committerJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-12-29 23:16:52 -0500
commitebd5c2cdda9a7114070021cbbc163054aa8f62da (patch)
treeaf38e769d5d783aec2cbb86e37dbc1cabab5b43f
parent6c606c1191287752d174439874fc7e820272cc49 (diff)
downloadrneovim-ebd5c2cdda9a7114070021cbbc163054aa8f62da.tar.gz
rneovim-ebd5c2cdda9a7114070021cbbc163054aa8f62da.tar.bz2
rneovim-ebd5c2cdda9a7114070021cbbc163054aa8f62da.zip
ui: add basic tests for pumheight,pumwidth
-rw-r--r--test/functional/ui/popupmenu_spec.lua38
1 files changed, 38 insertions, 0 deletions
diff --git a/test/functional/ui/popupmenu_spec.lua b/test/functional/ui/popupmenu_spec.lua
index 4c7f516c43..a0e5c3ca63 100644
--- a/test/functional/ui/popupmenu_spec.lua
+++ b/test/functional/ui/popupmenu_spec.lua
@@ -2019,4 +2019,42 @@ describe('builtin popupmenu', function()
{9:-- Keyword Local completion (^N^P) }{10:match 1 of 3} |
]])
end)
+
+ it("'pumheight'", function()
+ screen:try_resize(32,8)
+ feed('isome long prefix before the ')
+ command("set completeopt+=noinsert,noselect")
+ command("set linebreak")
+ command("set pumheight=2")
+ funcs.complete(29, {'word', 'choice', 'text', 'thing'})
+ screen:expect([[
+ some long prefix before the ^ |
+ {n:word }{c: }{1: }|
+ {n:choice }{s: }{1: }|
+ {1:~ }|
+ {1:~ }|
+ {1:~ }|
+ {1:~ }|
+ {2:-- INSERT --} |
+ ]])
+ end)
+
+ it("'pumwidth'", function()
+ screen:try_resize(32,8)
+ feed('isome long prefix before the ')
+ command("set completeopt+=noinsert,noselect")
+ command("set linebreak")
+ command("set pumwidth=8")
+ funcs.complete(29, {'word', 'choice', 'text', 'thing'})
+ screen:expect([[
+ some long prefix before the ^ |
+ {n:word }{1: }|
+ {n:choice }{1: }|
+ {n:text }{1: }|
+ {n:thing }{1: }|
+ {1:~ }|
+ {1:~ }|
+ {2:-- INSERT --} |
+ ]])
+ end)
end)