]> granicus.if.org Git - vim/commitdiff
patch 8.2.0923: cmdline test is slow v8.2.0923
authorBram Moolenaar <Bram@vim.org>
Sun, 7 Jun 2020 15:30:33 +0000 (17:30 +0200)
committerBram Moolenaar <Bram@vim.org>
Sun, 7 Jun 2020 15:30:33 +0000 (17:30 +0200)
Problem:    Cmdline test is slow.
Solution:   Use WaitForAssert().

src/testdir/test_cmdline.vim
src/version.c

index 94cb8273dc69a97fe41f80743fb2d5bc1065ed40..81350aa645c71a9fee4c68535b4d616fba265025 100644 (file)
@@ -3,6 +3,7 @@
 source check.vim
 source screendump.vim
 source view_util.vim
+source shared.vim
 
 func Test_complete_tab()
   call writefile(['testfile'], 'Xtestfile')
@@ -1194,13 +1195,12 @@ func Test_cmdwin_interrupted()
   call writefile(lines, 'XTest_cmdwin')
 
   let buf = RunVimInTerminal('-S XTest_cmdwin', {'rows': 18})
-  call TermWait(buf, 1000)
   " open cmdwin
   call term_sendkeys(buf, "q:")
-  call TermWait(buf, 500)
+  call WaitForAssert({-> assert_match('-- More --', term_getline(buf, 18))})
   " quit more prompt for :smile command
   call term_sendkeys(buf, "q")
-  call TermWait(buf, 500)
+  call WaitForAssert({-> assert_match('^$', term_getline(buf, 18))})
   " execute a simple command
   call term_sendkeys(buf, "aecho 'done'\<CR>")
   call VerifyScreenDump(buf, 'Test_cmdwin_interrupted', {})
index 64871c9205522d895c73bf59c614fba67b28ac23..5c39aa67d0f6472139cb2799adc039060b76fdac 100644 (file)
@@ -754,6 +754,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    923,
 /**/
     922,
 /**/