1
0
forked from aniani/vim

patch 8.2.0390: terminal postponed scrollback test is flaky

Problem:    Terminal postponed scrollback test is flaky.
Solution:   Add delay in between sending keys.  Rename dump files.
This commit is contained in:
Bram Moolenaar
2020-03-15 20:33:40 +01:00
parent e4fc746d13
commit ddbfe238a5
5 changed files with 10 additions and 6 deletions

View File

@@ -352,22 +352,24 @@ func Test_terminal_postponed_scrollback()
\ ], 'XTest_postponed')
let buf = RunVimInTerminal('-S XTest_postponed', {})
" Check that the Xtext lines are displayed and in Terminal-Normal mode
call VerifyScreenDump(buf, 'Test_terminal_01', {})
call VerifyScreenDump(buf, 'Test_terminal_scrollback_1', {})
silent !echo 'one more line' >>Xtext
" Screen will not change, move cursor to get a different dump
call term_sendkeys(buf, "k")
call VerifyScreenDump(buf, 'Test_terminal_02', {})
call VerifyScreenDump(buf, 'Test_terminal_scrollback_2', {})
" Back to Terminal-Job mode, text will scroll and show the extra line.
call term_sendkeys(buf, "a")
call VerifyScreenDump(buf, 'Test_terminal_03', {})
call VerifyScreenDump(buf, 'Test_terminal_scrollback_3', {})
call term_wait(buf)
" stop "tail -f"
call term_sendkeys(buf, "\<C-C>")
call term_wait(buf)
call term_wait(buf, 50)
" stop shell
call term_sendkeys(buf, "exit\<CR>")
call term_wait(buf)
call term_wait(buf, 100)
" close terminal window
let tsk_ret = term_sendkeys(buf, ":q\<CR>")
" check type of term_sendkeys() return value

View File

@@ -738,6 +738,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
390,
/**/
389,
/**/