aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2020-12-28 20:14:48 -0500
committerGitHub <noreply@github.com>2020-12-28 20:14:48 -0500
commitf5383705d1f49ef4d63490604eb7543ac1d5513b (patch)
treecd723a8cc21553645ea574b2180ee0294f201502 /src/nvim/testdir
parentb0215afc84102073554bb7cf990b881b33878ac1 (diff)
parentd712c30fff8cbe1328b12fc48d4572766db6c805 (diff)
downloadrneovim-f5383705d1f49ef4d63490604eb7543ac1d5513b.tar.gz
rneovim-f5383705d1f49ef4d63490604eb7543ac1d5513b.tar.bz2
rneovim-f5383705d1f49ef4d63490604eb7543ac1d5513b.zip
Merge pull request #13624 from janlazo/vim-8.2.2234
vim-patch:8.1.1032,8.2.{429,1785,2234,2235,2237,2241}
Diffstat (limited to 'src/nvim/testdir')
-rw-r--r--src/nvim/testdir/check.vim3
-rw-r--r--src/nvim/testdir/test_cmdline.vim29
2 files changed, 19 insertions, 13 deletions
diff --git a/src/nvim/testdir/check.vim b/src/nvim/testdir/check.vim
index 467ff5a1e9..24d3959f83 100644
--- a/src/nvim/testdir/check.vim
+++ b/src/nvim/testdir/check.vim
@@ -12,6 +12,9 @@ endfunc
" Command to check for the presence of a working option.
command -nargs=1 CheckOption call CheckOption(<f-args>)
func CheckOption(name)
+ if !exists('&' .. a:name)
+ throw 'Checking for non-existent option ' .. a:name
+ endif
if !exists('+' .. a:name)
throw 'Skipped: ' .. a:name .. ' option not supported'
endif
diff --git a/src/nvim/testdir/test_cmdline.vim b/src/nvim/testdir/test_cmdline.vim
index bb0cae4819..39f865144a 100644
--- a/src/nvim/testdir/test_cmdline.vim
+++ b/src/nvim/testdir/test_cmdline.vim
@@ -51,18 +51,21 @@ func Test_complete_wildmenu()
call feedkeys(":e Xdir1/\<Tab>\<Down>\<Up>\<Right>\<CR>", 'tx')
call assert_equal('testfile1', getline(1))
- + " <C-J>/<C-K> mappings to go up/down directories when 'wildcharm' is
- " different than 'wildchar'.
- set wildcharm=<C-Z>
- cnoremap <C-J> <Down><C-Z>
- cnoremap <C-K> <Up><C-Z>
- call feedkeys(":e Xdir1/\<Tab>\<C-J>\<CR>", 'tx')
- call assert_equal('testfile3', getline(1))
- call feedkeys(":e Xdir1/\<Tab>\<C-J>\<C-K>\<CR>", 'tx')
- call assert_equal('testfile1', getline(1))
- set wildcharm=0
- cunmap <C-J>
- cunmap <C-K>
+ " this fails in some Unix GUIs, not sure why
+ if !has('unix') || !has('gui_running')
+ " <C-J>/<C-K> mappings to go up/down directories when 'wildcharm' is
+ " different than 'wildchar'.
+ set wildcharm=<C-Z>
+ cnoremap <C-J> <Down><C-Z>
+ cnoremap <C-K> <Up><C-Z>
+ call feedkeys(":e Xdir1/\<Tab>\<C-J>\<CR>", 'tx')
+ call assert_equal('testfile3', getline(1))
+ call feedkeys(":e Xdir1/\<Tab>\<C-J>\<C-K>\<CR>", 'tx')
+ call assert_equal('testfile1', getline(1))
+ set wildcharm=0
+ cunmap <C-J>
+ cunmap <C-K>
+ endif
" cleanup
%bwipe
@@ -1001,4 +1004,4 @@ func Test_read_shellcmd()
endif
endfunc
-" vim: shiftwidth=2 sts=2 expandtab " vim: shiftwidth=2 sts=2 expandtab
+" vim: shiftwidth=2 sts=2 expandtab