diff options
author | Daniel Hahler <git@thequod.de> | 2019-12-22 11:23:39 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-22 11:23:39 +0100 |
commit | e1d63c180cc38cec5a8bf3e543bfe18472352da4 (patch) | |
tree | e31d61e1ce941bdf0c03dc0950f3cc1322be8997 /test/functional/terminal/ex_terminal_spec.lua | |
parent | 781c708c27816b07f1d20a333151886044534fab (diff) | |
download | rneovim-e1d63c180cc38cec5a8bf3e543bfe18472352da4.tar.gz rneovim-e1d63c180cc38cec5a8bf3e543bfe18472352da4.tar.bz2 rneovim-e1d63c180cc38cec5a8bf3e543bfe18472352da4.zip |
tests: ex_terminal_spec: retry ":terminal (with fake shell)" (#11588)
Flaky failure (Travis CI, macOS):
[ RUN ] :terminal (with fake shell) works with gf: 10518.41 ms FAIL
test/functional/terminal/ex_terminal_spec.lua:248: Row 1 did not match.
Expected:
|*^ready $ echo "scripts/shadacat.py" |
|* |
|*[Process exited 0] |
|:terminal echo "scripts/shadacat.py" |
Actual:
|*^ |
|*[Process exited 0] |
|* |
|:terminal echo "scripts/shadacat.py" |
To print the expect() call that would assert the current screen state, use
screen:snapshot_util(). In case of non-deterministic failures, use
screen:redraw_debug() to show all intermediate screen states.
stack traceback:
test/functional/ui/screen.lua:579: in function '_wait'
test/functional/ui/screen.lua:361: in function 'expect'
test/functional/terminal/ex_terminal_spec.lua:248: in function <test/functional/terminal/ex_terminal_spec.lua:245>
Diffstat (limited to 'test/functional/terminal/ex_terminal_spec.lua')
-rw-r--r-- | test/functional/terminal/ex_terminal_spec.lua | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/functional/terminal/ex_terminal_spec.lua b/test/functional/terminal/ex_terminal_spec.lua index b0019d2d37..138befd978 100644 --- a/test/functional/terminal/ex_terminal_spec.lua +++ b/test/functional/terminal/ex_terminal_spec.lua @@ -245,12 +245,14 @@ describe(':terminal (with fake shell)', function() it('works with gf', function() command('set shellxquote=') -- win: avoid extra quotes terminal_with_fake_shell([[echo "scripts/shadacat.py"]]) + retry(nil, 4 * screen.timeout, function() screen:expect([[ ^ready $ echo "scripts/shadacat.py" | | [Process exited 0] | :terminal echo "scripts/shadacat.py" | ]]) + end) feed([[<C-\><C-N>]]) eq('term://', string.match(eval('bufname("%")'), "^term://")) feed([[ggf"lgf]]) |