mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
tests: fix flaky "TermClose … fast-exiting terminal job stops"
This extra retry() was removed (at my suggestion) in 5b94a2977a
, but
it is probably needed: jobwait(…, timeout=0) could return while
channel_process_exit_cb() is still queued (so TermClose event didn't
fire yet).
20:46:21,288 INFO - not ok 547 - TermClose event triggers when fast-exiting terminal job stops
20:46:21,288 INFO - # test/functional/autocmd/termclose_spec.lua @ 20
20:46:21,288 INFO - # Failure message: ./test/functional/helpers.lua:98: Vim:E121: Undefined variable: g:test_termclose
20:46:21,288 INFO - # stack traceback:
20:46:21,288 INFO - # ./test/functional/helpers.lua:98: in function 'eval'
20:46:21,288 INFO - # test/functional/autocmd/termclose_spec.lua:25: in function <test/functional/autocmd/termclose_spec.lua:20>
This commit is contained in:
parent
6871445dfe
commit
c516586dc3
@ -22,7 +22,7 @@ describe('TermClose event', function()
|
||||
command('terminal')
|
||||
-- shell-test exits immediately.
|
||||
retry(nil, nil, function() neq(-1, eval('jobwait([&channel], 0)[0]')) end)
|
||||
eq(23, eval('g:test_termclose'))
|
||||
retry(nil, nil, function() eq(23, eval('g:test_termclose')) end)
|
||||
end)
|
||||
|
||||
it('triggers when long-running terminal job gets stopped', function()
|
||||
|
Loading…
Reference in New Issue
Block a user