From c3931495b28776dc8eec4814aa469522e37b179b Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sat, 2 Jan 2021 18:49:21 -0500 Subject: [PATCH] vim-patch:8.2.0470: Test_confirm_cmd_cancel() can fail on a slow system Problem: Test_confirm_cmd_cancel() can fail on a slow system. Solution: Use WaitForAssert(). (Ozaki Kiichi, closes vim/vim#5861) https://github.com/vim/vim/commit/7b1b36b1cb744e87adfbef88b7ce26c863b0594a --- src/nvim/testdir/test_excmd.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nvim/testdir/test_excmd.vim b/src/nvim/testdir/test_excmd.vim index 1b4859ad6d..9afb2b3b66 100644 --- a/src/nvim/testdir/test_excmd.vim +++ b/src/nvim/testdir/test_excmd.vim @@ -111,7 +111,7 @@ func Test_confirm_cmd_cancel() call WaitForAssert({-> assert_match('^\[Y\]es, (N)o, (C)ancel: *$', \ term_getline(buf, 20))}, 1000) call term_sendkeys(buf, "C") - call term_wait(buf, 50) + call WaitForAssert({-> assert_equal('', term_getline(buf, 20))}, 1000) call term_sendkeys(buf, ":confirm close\n") call WaitForAssert({-> assert_match('^\[Y\]es, (N)o, (C)ancel: *$', \ term_getline(buf, 20))}, 1000)