summaryrefslogtreecommitdiff
path: root/src/testdir/test_popupwin.vim
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-09-28 22:29:58 +0200
committerBram Moolenaar <Bram@vim.org>2020-09-28 22:29:58 +0200
commit4934ad0e448bfa03ba19c7c5b411c457a9910442 (patch)
treebe240c37e3e2be89bde36969b2287a934b4209fc /src/testdir/test_popupwin.vim
parentd58a3bf7dac8d53faf42e13cc1152b110f12c404 (diff)
downloadvim-git-4934ad0e448bfa03ba19c7c5b411c457a9910442.tar.gz
patch 8.2.1769: popup filter interferes with using :normal to move the cursorv8.2.1769
Problem: A popup filter interferes with using :normal to move the cursor in a popup. Solution: Do not invoke the filter when ex_normal_busy is set.
Diffstat (limited to 'src/testdir/test_popupwin.vim')
-rw-r--r--src/testdir/test_popupwin.vim7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/testdir/test_popupwin.vim b/src/testdir/test_popupwin.vim
index ea2ee3b5c..e991fc116 100644
--- a/src/testdir/test_popupwin.vim
+++ b/src/testdir/test_popupwin.vim
@@ -1539,13 +1539,14 @@ func Test_popup_filter()
call popup_clear()
endfunc
-" this tests that the "ex_normal_busy_done" flag works
+" this tests that the filter is not used for :normal command
func Test_popup_filter_normal_cmd()
CheckScreendump
let lines =<< trim END
- let g:winid = popup_create('some text', {'filter': 'invalidfilter'})
- call timer_start(0, {-> win_execute(g:winid, 'norm! zz')})
+ let text = range(1, 20)->map({_, v -> string(v)})
+ let g:winid = popup_create(text, #{maxheight: 5, minwidth: 3, filter: 'invalidfilter'})
+ call timer_start(0, {-> win_execute(g:winid, 'norm! 10Gzz')})
END
call writefile(lines, 'XtestPopupNormal')
let buf = RunVimInTerminal('-S XtestPopupNormal', #{rows: 10})