forked from aniani/vim
patch 8.2.1803: a few failures are not tested
Problem: A few failures are not tested. Solution: Test a few failures. (Dominique Pellé, closes #7075)
This commit is contained in:
@@ -426,6 +426,7 @@ func Test_argdelete()
|
|||||||
call assert_fails('argdelete', 'E610:')
|
call assert_fails('argdelete', 'E610:')
|
||||||
call assert_fails('1,100argdelete', 'E16:')
|
call assert_fails('1,100argdelete', 'E16:')
|
||||||
call assert_fails('argdel /\)/', 'E55:')
|
call assert_fails('argdel /\)/', 'E55:')
|
||||||
|
call assert_fails('1argdel 1', 'E474:')
|
||||||
|
|
||||||
call Reset_arglist()
|
call Reset_arglist()
|
||||||
args a b c d
|
args a b c d
|
||||||
@@ -478,13 +479,16 @@ func Test_arglist_autocmd()
|
|||||||
new
|
new
|
||||||
" redefine arglist; go to Xxx1
|
" redefine arglist; go to Xxx1
|
||||||
next! Xxx1 Xxx2 Xxx3
|
next! Xxx1 Xxx2 Xxx3
|
||||||
" open window for all args
|
" open window for all args; Reading Xxx2 will change the arglist and the
|
||||||
|
" third window will get Xxx1:
|
||||||
|
" win 1: Xxx1
|
||||||
|
" win 2: Xxx2
|
||||||
|
" win 3: Xxx1
|
||||||
all
|
all
|
||||||
call assert_equal('test file Xxx1', getline(1))
|
call assert_equal('test file Xxx1', getline(1))
|
||||||
wincmd w
|
wincmd w
|
||||||
wincmd w
|
wincmd w
|
||||||
call assert_equal('test file Xxx1', getline(1))
|
call assert_equal('test file Xxx1', getline(1))
|
||||||
" should now be in Xxx2
|
|
||||||
rewind
|
rewind
|
||||||
call assert_equal('test file Xxx2', getline(1))
|
call assert_equal('test file Xxx2', getline(1))
|
||||||
|
|
||||||
|
@@ -756,6 +756,10 @@ func Test_cmdline_complete_various()
|
|||||||
call feedkeys(":doautocmd User MyCmd a.c\<C-A>\<C-B>\"\<CR>", 'xt')
|
call feedkeys(":doautocmd User MyCmd a.c\<C-A>\<C-B>\"\<CR>", 'xt')
|
||||||
call assert_equal("\"doautocmd User MyCmd a.c\<C-A>", @:)
|
call assert_equal("\"doautocmd User MyCmd a.c\<C-A>", @:)
|
||||||
|
|
||||||
|
" completion of autocmd group after comma
|
||||||
|
call feedkeys(":doautocmd BufNew,BufEn\<C-A>\<C-B>\"\<CR>", 'xt')
|
||||||
|
call assert_equal("\"doautocmd BufNew,BufEnter", @:)
|
||||||
|
|
||||||
" completion for the :augroup command
|
" completion for the :augroup command
|
||||||
augroup XTest
|
augroup XTest
|
||||||
augroup END
|
augroup END
|
||||||
|
@@ -196,6 +196,7 @@ func Test_json_decode()
|
|||||||
call assert_fails('call json_decode("{[]:42}")', "E491:")
|
call assert_fails('call json_decode("{[]:42}")', "E491:")
|
||||||
|
|
||||||
call assert_fails('call json_decode("-")', "E491:")
|
call assert_fails('call json_decode("-")', "E491:")
|
||||||
|
call assert_fails('call json_decode("-1x")', "E491:")
|
||||||
call assert_fails('call json_decode("infinit")', "E491:")
|
call assert_fails('call json_decode("infinit")', "E491:")
|
||||||
|
|
||||||
call assert_fails('call json_decode("\"\\u111Z\"")', 'E491:')
|
call assert_fails('call json_decode("\"\\u111Z\"")', 'E491:')
|
||||||
|
@@ -726,6 +726,8 @@ func Test_reduce()
|
|||||||
call assert_fails("call reduce({}, { acc, val -> acc + val }, 1)", 'E897:')
|
call assert_fails("call reduce({}, { acc, val -> acc + val }, 1)", 'E897:')
|
||||||
call assert_fails("call reduce(0, { acc, val -> acc + val }, 1)", 'E897:')
|
call assert_fails("call reduce(0, { acc, val -> acc + val }, 1)", 'E897:')
|
||||||
call assert_fails("call reduce('', { acc, val -> acc + val }, 1)", 'E897:')
|
call assert_fails("call reduce('', { acc, val -> acc + val }, 1)", 'E897:')
|
||||||
|
call assert_fails("call reduce([1, 2], 'Xdoes_not_exist')", 'E117:')
|
||||||
|
call assert_fails("echo reduce(0z01, { acc, val -> 2 * acc + val }, '')", 'E39:')
|
||||||
|
|
||||||
let g:lut = [1, 2, 3, 4]
|
let g:lut = [1, 2, 3, 4]
|
||||||
func EvilRemove()
|
func EvilRemove()
|
||||||
|
@@ -750,6 +750,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
1803,
|
||||||
/**/
|
/**/
|
||||||
1802,
|
1802,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user