aboutsummaryrefslogtreecommitdiff
path: root/test/functional/terminal
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/terminal')
-rw-r--r--test/functional/terminal/buffer_spec.lua6
-rw-r--r--test/functional/terminal/helpers.lua2
-rw-r--r--test/functional/terminal/mouse_spec.lua4
-rw-r--r--test/functional/terminal/scrollback_spec.lua8
-rw-r--r--test/functional/terminal/tui_spec.lua14
5 files changed, 13 insertions, 21 deletions
diff --git a/test/functional/terminal/buffer_spec.lua b/test/functional/terminal/buffer_spec.lua
index 1763574bf9..7560b0e872 100644
--- a/test/functional/terminal/buffer_spec.lua
+++ b/test/functional/terminal/buffer_spec.lua
@@ -208,18 +208,18 @@ describe(':terminal buffer', function()
feed_command('terminal')
feed('<c-\\><c-n>')
feed_command('confirm bdelete')
- screen:expect{any='Close "term://', attr_ignore=true}
+ screen:expect{any='Close "term://'}
end)
it('with &confirm', function()
feed_command('terminal')
feed('<c-\\><c-n>')
feed_command('bdelete')
- screen:expect{any='E89', attr_ignore=true}
+ screen:expect{any='E89'}
feed('<cr>')
eq('terminal', eval('&buftype'))
feed_command('set confirm | bdelete')
- screen:expect{any='Close "term://', attr_ignore=true}
+ screen:expect{any='Close "term://'}
feed('y')
neq('terminal', eval('&buftype'))
end)
diff --git a/test/functional/terminal/helpers.lua b/test/functional/terminal/helpers.lua
index f6cab6bd1e..d909888613 100644
--- a/test/functional/terminal/helpers.lua
+++ b/test/functional/terminal/helpers.lua
@@ -52,7 +52,7 @@ local function screen_setup(extra_rows, command, cols, opts)
[3] = {bold = true},
[4] = {foreground = 12},
[5] = {bold = true, reverse = true},
- [6] = {background = 11},
+ -- 6 was a duplicate item
[7] = {foreground = 130},
[8] = {foreground = 15, background = 1}, -- error message
[9] = {foreground = 4},
diff --git a/test/functional/terminal/mouse_spec.lua b/test/functional/terminal/mouse_spec.lua
index 64f437f206..ee3db7ae97 100644
--- a/test/functional/terminal/mouse_spec.lua
+++ b/test/functional/terminal/mouse_spec.lua
@@ -31,10 +31,6 @@ describe(':terminal mouse', function()
]])
end)
- after_each(function()
- screen:detach()
- end)
-
describe('when the terminal has focus', function()
it('will exit focus on mouse-scroll', function()
eq('t', eval('mode()'))
diff --git a/test/functional/terminal/scrollback_spec.lua b/test/functional/terminal/scrollback_spec.lua
index ff6a74fe89..060f065bfc 100644
--- a/test/functional/terminal/scrollback_spec.lua
+++ b/test/functional/terminal/scrollback_spec.lua
@@ -21,10 +21,6 @@ describe(':terminal scrollback', function()
screen = thelpers.screen_setup(nil, nil, 30)
end)
- after_each(function()
- screen:detach()
- end)
-
describe('when the limit is exceeded', function()
before_each(function()
local lines = {}
@@ -406,8 +402,6 @@ describe("'scrollback' option", function()
feed_data(nvim_dir..'/shell-test REP 31 line'..(iswin() and '\r' or '\n'))
screen:expect{any='30: line '}
retry(nil, nil, function() expect_lines(7) end)
-
- screen:detach()
end)
it('deletes lines (only) if necessary', function()
@@ -464,8 +458,6 @@ describe("'scrollback' option", function()
-- Verify off-screen state
eq((iswin() and '36: line' or '35: line'), eval("getline(line('w0') - 1)"))
eq((iswin() and '27: line' or '26: line'), eval("getline(line('w0') - 10)"))
-
- screen:detach()
end)
it('defaults to 10000 in :terminal buffers', function()
diff --git a/test/functional/terminal/tui_spec.lua b/test/functional/terminal/tui_spec.lua
index 978267e040..4f5cfa930a 100644
--- a/test/functional/terminal/tui_spec.lua
+++ b/test/functional/terminal/tui_spec.lua
@@ -45,10 +45,6 @@ describe('TUI', function()
child_session = helpers.connect(child_server)
end)
- after_each(function()
- screen:detach()
- end)
-
-- Wait for mode in the child Nvim (avoid "typeahead race" #10826).
local function wait_for_mode(mode)
retry(nil, nil, function()
@@ -928,7 +924,15 @@ describe('TUI FocusGained/FocusLost', function()
feed_data(':terminal\n')
-- Wait for terminal to be ready.
- screen:expect{any='-- TERMINAL --'}
+ screen:expect{grid=[[
+ {1:r}eady $ |
+ [Process exited 0] |
+ |
+ |
+ |
+ :terminal |
+ {3:-- TERMINAL --} |
+ ]]}
feed_data('\027[I')
screen:expect{grid=[[