diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2018-09-23 10:53:57 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-23 10:53:57 +0200 |
commit | eee93f36d8cd7545c444e5e3aaad5d5bcd0ef365 (patch) | |
tree | e34fad420042ad56953f8275531db92c32b9aafe /src/nvim/testdir/test_options.vim | |
parent | 197d907e092aa6db9bd0e75003438f11cd6812bf (diff) | |
parent | bcc174e6df50c87808dae0430fa4b95659678058 (diff) | |
download | rneovim-eee93f36d8cd7545c444e5e3aaad5d5bcd0ef365.tar.gz rneovim-eee93f36d8cd7545c444e5e3aaad5d5bcd0ef365.tar.bz2 rneovim-eee93f36d8cd7545c444e5e3aaad5d5bcd0ef365.zip |
Merge #9031 from janlazo/vim-8.1.0414
Diffstat (limited to 'src/nvim/testdir/test_options.vim')
-rw-r--r-- | src/nvim/testdir/test_options.vim | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_options.vim b/src/nvim/testdir/test_options.vim index 3e0703f845..66acb79206 100644 --- a/src/nvim/testdir/test_options.vim +++ b/src/nvim/testdir/test_options.vim @@ -29,6 +29,19 @@ function! Test_isfname() set isfname& endfunction +function Test_wildchar() + " Empty 'wildchar' used to access invalid memory. + call assert_fails('set wildchar=', 'E521:') + call assert_fails('set wildchar=abc', 'E521:') + set wildchar=<Esc> + let a=execute('set wildchar?') + call assert_equal("\n wildchar=<Esc>", a) + set wildchar=27 + let a=execute('set wildchar?') + call assert_equal("\n wildchar=<Esc>", a) + set wildchar& +endfunction + function! Test_options() let caught = 'ok' try @@ -356,6 +369,24 @@ func Test_shortmess_F() bwipe endfunc +func Test_set_all() + set tw=75 + set iskeyword=a-z,A-Z + set nosplitbelow + let out = execute('set all') + call assert_match('textwidth=75', out) + call assert_match('iskeyword=a-z,A-Z', out) + call assert_match('nosplitbelow', out) + set tw& iskeyword& splitbelow& +endfunc + +func Test_set_values() + " The file is only generated when running "make test" in the src directory. + if filereadable('opt_test.vim') + source opt_test.vim + endif +endfunc + func Test_shortmess_F2() e file1 e file2 |