aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir/test_cmdline.vim
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-12-08 22:52:25 +0800
committerGitHub <noreply@github.com>2022-12-08 22:52:25 +0800
commit7b9ad45178fc2f53c4824ad42213c340bdd66ebf (patch)
tree56368b3c4bad99050aeac1fbf21bd3cd59dbcd38 /src/nvim/testdir/test_cmdline.vim
parent50ffb8d7f4d9e1b080efbf5eb04595f0399db9e5 (diff)
downloadrneovim-7b9ad45178fc2f53c4824ad42213c340bdd66ebf.tar.gz
rneovim-7b9ad45178fc2f53c4824ad42213c340bdd66ebf.tar.bz2
rneovim-7b9ad45178fc2f53c4824ad42213c340bdd66ebf.zip
vim-patch:8.2.1634: loop to handle keys for the command line is too long (#21340)
Problem: Loop to handle keys for the command line is too long. Solution: Move a few more parts to separate functions. (Yegappan Lakshmanan, closes vim/vim#6895) https://github.com/vim/vim/commit/9c929713b7588f2e44a1533809d2ba0bbd2631be
Diffstat (limited to 'src/nvim/testdir/test_cmdline.vim')
-rw-r--r--src/nvim/testdir/test_cmdline.vim9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_cmdline.vim b/src/nvim/testdir/test_cmdline.vim
index b9da4ca7bb..218a2143e8 100644
--- a/src/nvim/testdir/test_cmdline.vim
+++ b/src/nvim/testdir/test_cmdline.vim
@@ -1100,6 +1100,15 @@ func Test_cmdline_complete_various()
" completion after a range followed by a pipe (|) character
call feedkeys(":1,10 | chist\t\<C-B>\"\<CR>", 'xt')
call assert_equal('"1,10 | chistory', @:)
+
+ " use <Esc> as the 'wildchar' for completion
+ set wildchar=<Esc>
+ call feedkeys(":g/a\\xb/clearj\<Esc>\<C-B>\"\<CR>", 'xt')
+ call assert_equal('"g/a\xb/clearjumps', @:)
+ " pressing <esc> twice should cancel the command
+ call feedkeys(":chist\<Esc>\<Esc>", 'xt')
+ call assert_equal('"g/a\xb/clearjumps', @:)
+ set wildchar&
endfunc
func Test_cmdline_write_alternatefile()