diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2019-02-12 20:22:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-12 20:22:28 +0100 |
commit | 73dffc5053c06a81373c1f0f9344bfd76352b345 (patch) | |
tree | 84424f03bc722d2ce3b695132dc5a4b8a1d3b02d /test | |
parent | 9b4383261a3de874969b7df89d32eaeb92ab8abf (diff) | |
parent | e50d0b6fc19fe7555651166b73aff9c3703ef11a (diff) | |
download | rneovim-73dffc5053c06a81373c1f0f9344bfd76352b345.tar.gz rneovim-73dffc5053c06a81373c1f0f9344bfd76352b345.tar.bz2 rneovim-73dffc5053c06a81373c1f0f9344bfd76352b345.zip |
Merge #9589 from justinmk/cterm-pumblend
UI: 'pumblend' for cterm (256-color TUI)
Diffstat (limited to 'test')
-rw-r--r-- | test/functional/ui/popupmenu_spec.lua | 39 |
1 files changed, 38 insertions, 1 deletions
diff --git a/test/functional/ui/popupmenu_spec.lua b/test/functional/ui/popupmenu_spec.lua index 62428c9657..9a8c5a5789 100644 --- a/test/functional/ui/popupmenu_spec.lua +++ b/test/functional/ui/popupmenu_spec.lua @@ -1273,7 +1273,7 @@ describe('builtin popupmenu', function() ]]) end) - it('works with pumblend', function() + it("'pumblend' RGB-color", function() screen:try_resize(60,14) screen:set_default_attr_ids({ [1] = {background = Screen.colors.Yellow}, @@ -1448,4 +1448,41 @@ describe('builtin popupmenu', function() {20:-- INSERT --} | ]]) end) + + it("'pumblend' 256-color (non-RGB)", function() + screen:detach() + screen = Screen.new(60, 8) + screen:attach({rgb=false, ext_popupmenu=false}) + screen:set_default_attr_ids({ + [1] = {foreground = Screen.colors.Grey0, background = tonumber('0x000007')}, + [2] = {foreground = tonumber('0x000055'), background = tonumber('0x000007')}, + [3] = {foreground = tonumber('0x00008f'), background = Screen.colors.Grey0}, + [4] = {foreground = Screen.colors.Grey0, background = tonumber('0x0000e1')}, + [5] = {foreground = tonumber('0x0000d1'), background = tonumber('0x0000e1')}, + [6] = {foreground = Screen.colors.NavyBlue, background = tonumber('0x0000f8')}, + [7] = {foreground = tonumber('0x0000a5'), background = tonumber('0x0000f8')}, + [8] = {foreground = tonumber('0x00000c')}, + [9] = {bold = true}, + [10] = {foreground = tonumber('0x000002')}, + }) + command('set notermguicolors pumblend=10') + insert([[ + Lorem ipsum dolor sit amet, consectetur + adipisicing elit, sed do eiusmod tempor + incididunt ut labore et dolore magna aliqua. + Ut enim ad minim veniam, quis nostrud + laborum.]]) + + feed('ggOdo<c-x><c-n>') + screen:expect([[ + dolor^ | + {1:dolor}{2: ipsum dol}or sit amet, consectetur | + {4:do}{5:ipisicing eli}t, sed do eiusmod tempor | + {4:dolore}{5:dunt ut l}abore et dolore magna aliqua. | + Ut enim ad minim veniam, quis nostrud | + laborum. | + {8:~ }| + {9:-- Keyword Local completion (^N^P) }{10:match 1 of 3} | + ]]) + end) end) |