mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
test/win: window_split_tab_spec: fix retry()
This commit is contained in:
parent
10ef903648
commit
6fe740c7ab
@ -69,19 +69,21 @@ describe('terminal', function()
|
||||
|
||||
it('forwards resize request to the program', function()
|
||||
feed([[<C-\><C-N>:]]) -- Go to cmdline-mode, so cursor is at bottom.
|
||||
local w1, h1 = screen._width - 3, screen._height - 2
|
||||
local w2, h2 = w1 - 6, h1 - 3
|
||||
|
||||
if iswin() then
|
||||
-- win: SIGWINCH is unreliable, use a weaker test. #7506
|
||||
retry(3, 30000, function()
|
||||
-- win: SIGWINCH is unreliable. #7506
|
||||
screen:try_resize(screen._width - 3, screen._height - 2)
|
||||
screen:try_resize(w1, h1)
|
||||
screen:expect{any='rows: 7, cols: 47'}
|
||||
screen:try_resize(screen._width - 6, screen._height - 3)
|
||||
screen:try_resize(w2, h2)
|
||||
screen:expect{any='rows: 4, cols: 41'}
|
||||
end)
|
||||
return
|
||||
end
|
||||
|
||||
screen:try_resize(screen._width - 3, screen._height - 2)
|
||||
screen:try_resize(w1, h1)
|
||||
screen:expect([[
|
||||
tty ready |
|
||||
rows: 7, cols: 47 |
|
||||
@ -92,7 +94,7 @@ describe('terminal', function()
|
||||
|
|
||||
:^ |
|
||||
]])
|
||||
screen:try_resize(screen._width - 6, screen._height - 3)
|
||||
screen:try_resize(w2, h2)
|
||||
screen:expect([[
|
||||
tty ready |
|
||||
rows: 7, cols: 47 |
|
||||
|
Loading…
Reference in New Issue
Block a user