comparison src/testdir/test_timers.vim @ 30447:db70368fd2b9 v9.0.0559

patch 9.0.0559: timer test may get stuck at hit-enter prompt Commit: https://github.com/vim/vim/commit/4ecf16bbf951f10fd32c918c9d8bc004b7f8f7c9 Author: Bram Moolenaar <Bram@vim.org> Date: Fri Sep 23 18:22:21 2022 +0100 patch 9.0.0559: timer test may get stuck at hit-enter prompt Problem: Timer test may get stuck at hit-enter prompt. Solution: Feed some more characters.
author Bram Moolenaar <Bram@vim.org>
date Fri, 23 Sep 2022 19:30:05 +0200
parents fd855ad74887
children 7ab65e398be7
comparison
equal deleted inserted replaced
30446:58da8a140312 30447:db70368fd2b9
377 func CauseAnError(id) 377 func CauseAnError(id)
378 " This will show an error and wait for Enter. 378 " This will show an error and wait for Enter.
379 let a = {'foo', 'bar'} 379 let a = {'foo', 'bar'}
380 endfunc 380 endfunc
381 func FeedChar(id) 381 func FeedChar(id)
382 call feedkeys('x', 't') 382 call feedkeys(":\<CR>", 't')
383 endfunc 383 endfunc
384 call timer_start(300, 'FeedChar') 384 call timer_start(300, 'FeedChar')
385 call timer_start(100, 'CauseAnError') 385 call timer_start(100, 'CauseAnError')
386 let x = getchar() 386 let x = getchar() " wait for error in timer
387 let x = getchar(0) " read any remaining chars
388 let x = getchar(0)
387 389
388 set ut& 390 set ut&
389 call test_override('no_wait_return', 1) 391 call test_override('no_wait_return', 1)
390 delfunc CauseAnError 392 delfunc CauseAnError
391 delfunc FeedChar 393 delfunc FeedChar