Skip to content

Commit 27f4f6b

Browse files
committed
patch 8.2.1998: terminal Cmd test sometimes fails to close popup
Problem: Terminal Cmd test sometimes fails to close popup. Solution: Add "term_finish" option.
1 parent 8adc8d9 commit 27f4f6b

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

src/testdir/test_terminal.vim

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1259,15 +1259,14 @@ func Test_terminal_popup_insert_cmd()
12591259

12601260
inoremap <F3> <Cmd>call StartTermInPopup()<CR>
12611261
func StartTermInPopup()
1262-
call term_start(['/bin/sh', '-c', 'cat'], #{hidden: v:true})->popup_create(#{highlight: 'Pmenu'})
1262+
call term_start(['/bin/sh', '-c', 'cat'], #{hidden: v:true, term_finish: 'close'})->popup_create(#{highlight: 'Pmenu'})
12631263
endfunc
12641264
call feedkeys("i\<F3>")
12651265
sleep 10m
12661266
call assert_equal('n', mode())
12671267

12681268
call feedkeys("\<C-D>", 'xt')
1269-
sleep 20m
1270-
call feedkeys(":q\<CR>", 'xt')
1269+
sleep 50m
12711270
delfunc StartTermInPopup
12721271
iunmap <F3>
12731272
endfunc

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -750,6 +750,8 @@ static char *(features[]) =
750750

751751
static int included_patches[] =
752752
{ /* Add new patch number below this line */
753+
/**/
754+
1998,
753755
/**/
754756
1997,
755757
/**/

0 commit comments

Comments
 (0)