]> granicus.if.org Git - vim/commitdiff
patch 8.2.1264: terminal getwinpos() test is a bit flaky v8.2.1264
authorBram Moolenaar <Bram@vim.org>
Tue, 21 Jul 2020 19:48:58 +0000 (21:48 +0200)
committerBram Moolenaar <Bram@vim.org>
Tue, 21 Jul 2020 19:48:58 +0000 (21:48 +0200)
Problem:    Terminal getwinpos() test is a bit flaky.
Solution:   Call getwinpos() a bit later.

src/testdir/test_terminal3.vim
src/version.c

index 8405cd16a489840141402f32972d57fe6b5d9bbe..76e8a105433850484fc03330d6dcae12f8ca24f8 100644 (file)
@@ -527,11 +527,9 @@ func Test_terminal_getwinpos()
   wincmd j
   set splitright
 
-  call writefile([
-       \ 'echo getwinpos()',
-       \ ], 'XTest_getwinpos')
-  let buf = RunVimInTerminal('-S XTest_getwinpos', {'cols': 60})
-  call TermWait(buf)
+  let buf = RunVimInTerminal('', {'cols': 60})
+  call TermWait(buf, 100)
+  call term_sendkeys(buf, ":echo getwinpos(500)\<CR>")
 
   " Find the output of getwinpos() in the bottom line.
   let rows = term_getsize(buf)[0]
@@ -557,7 +555,6 @@ func Test_terminal_getwinpos()
   call TermWait(buf)
   call term_sendkeys(buf, ":q\<CR>")
   call StopVimInTerminal(buf)
-  call delete('XTest_getwinpos')
   exe buf . 'bwipe!'
   set splitright&
   only!
index a26908213ca13409ced1e9436750fecbd53cacd3..9b6f1b41a3e82f310f7f68240727f379af145883 100644 (file)
@@ -754,6 +754,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1264,
 /**/
     1263,
 /**/