]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 8.2.1036: popupwin test fails sometimes v8.2.1036
authorBram Moolenaar <Bram@vim.org>
Mon, 22 Jun 2020 17:24:23 +0000 (19:24 +0200)
committerBram Moolenaar <Bram@vim.org>
Mon, 22 Jun 2020 17:24:23 +0000 (19:24 +0200)
Problem:    Popupwin test fails sometimes.
Solution:   Use WaitForAssert() instead of a sleep.

src/testdir/test_popupwin.vim
src/version.c

index 42f4256c3ea0d796dd193bde87075780041ed370..80a14595e0ed421081725f51f635474ec3f453c6 100644 (file)
@@ -2454,9 +2454,11 @@ func Test_popupwin_terminal_buffer()
   call term_sendkeys(termbuf2, "exit\<CR>")
 
   " Exiting shell closes popup window
+  let pupwin = win_getid()
   call feedkeys("exit\<CR>", 'xt')
   " Wait for shell to exit
-  sleep 100m
+  call WaitForAssert({-> assert_notequal(pupwin, win_getid())})
+
   call feedkeys(":quit\<CR>", 'xt')
   call assert_equal(origwin, win_getid())
 endfunc
index 3c6b744b5612fefd2a083c259650bffeebfe114b..42c03d09222565788819dee91d503c0f2548c19d 100644 (file)
@@ -754,6 +754,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1036,
 /**/
     1035,
 /**/