diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-01-13 15:25:32 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-01-13 15:25:32 +0000 |
commit | ced2b38a560cc4f4ec983ed2cf4372ab62e1dbc1 (patch) | |
tree | f77792c0e5856a8d1cd5a4625852e045c83f4d0b /src/testdir/term_util.vim | |
parent | 8d9e470aa91a93da7d6bda62521aef69a79e956d (diff) |
patch 8.2.4078: terminal test for current directory not used on FreeBSDv8.2.4078
Problem: Terminal test for current directory not used on FreeBSD.
Solution: Make it work on FreeBSD. (Ozaki Kiichi, closes #9516) Add
TermWait() inside Run_shell_in_terminal() as a generic solution.
Diffstat (limited to 'src/testdir/term_util.vim')
-rw-r--r-- | src/testdir/term_util.vim | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/testdir/term_util.vim b/src/testdir/term_util.vim index de87dd420e..d748ed057b 100644 --- a/src/testdir/term_util.vim +++ b/src/testdir/term_util.vim @@ -24,6 +24,7 @@ func StopShellInTerminal(buf) call term_sendkeys(a:buf, "exit\r") let job = term_getjob(a:buf) call WaitForAssert({-> assert_equal("dead", job_status(job))}) + call TermWait(a:buf) endfunc " Wrapper around term_wait() to allow more time for re-runs of flaky tests @@ -176,6 +177,10 @@ func Run_shell_in_terminal(options) let string = string({'job': buf->term_getjob()}) call assert_match("{'job': 'process \\d\\+ run'}", string) + " On slower systems it may take a bit of time before the shell is ready to + " accept keys. This mainly matters when using term_sendkeys() next. + call TermWait(buf) + return buf endfunc |