aboutsummaryrefslogtreecommitdiff
path: root/test/functional/ui/screen_basic_spec.lua
diff options
context:
space:
mode:
authorBjörn Linse <bjorn.linse@gmail.com>2021-03-23 08:51:20 +0100
committerBjörn Linse <bjorn.linse@gmail.com>2021-03-23 09:34:36 +0100
commit80e122ae5d6bc02c8bea33528f0e1d16e48489b6 (patch)
treef14dbe654b7a186980c1d81c567c4be9374af373 /test/functional/ui/screen_basic_spec.lua
parentd41778c993e95c8b37b3d8e10dacc3060ae489da (diff)
downloadrneovim-80e122ae5d6bc02c8bea33528f0e1d16e48489b6.tar.gz
rneovim-80e122ae5d6bc02c8bea33528f0e1d16e48489b6.tar.bz2
rneovim-80e122ae5d6bc02c8bea33528f0e1d16e48489b6.zip
screen: setup scrolling main screen when starting with display-=msgsep
Diffstat (limited to 'test/functional/ui/screen_basic_spec.lua')
-rw-r--r--test/functional/ui/screen_basic_spec.lua44
1 files changed, 36 insertions, 8 deletions
diff --git a/test/functional/ui/screen_basic_spec.lua b/test/functional/ui/screen_basic_spec.lua
index ff9f30d0a1..958e137f65 100644
--- a/test/functional/ui/screen_basic_spec.lua
+++ b/test/functional/ui/screen_basic_spec.lua
@@ -24,10 +24,6 @@ describe('screen', function()
} )
end)
- after_each(function()
- screen:detach()
- end)
-
it('default initial screen', function()
screen:expect([[
^ |
@@ -67,10 +63,6 @@ local function screen_tests(linegrid)
} )
end)
- after_each(function()
- screen:detach()
- end)
-
describe(':suspend', function()
it('is forwarded to the UI', function()
local function check()
@@ -1004,3 +996,39 @@ describe('Screen default colors', function()
end}
end)
end)
+
+
+describe('screen with msgsep deactivated on startup', function()
+ local screen
+
+ before_each(function()
+ clear('--cmd', 'set display-=msgsep')
+ screen = Screen.new()
+ screen:attach()
+ screen:set_default_attr_ids {
+ [0] = {bold=true, foreground=255};
+ [7] = {bold = true, foreground = Screen.colors.SeaGreen};
+ }
+ end)
+
+ it('execute command with multi-line output', function()
+ feed ':ls<cr>'
+ screen:expect([[
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ {0:~ }|
+ :ls |
+ 1 %a "[No Name]" line 1 |
+ {7:Press ENTER or type command to continue}^ |
+ ]])
+ feed '<cr>' -- skip the "Press ENTER..." state or tests will hang
+ end)
+end)