forked from aniani/vim
patch 9.0.1524: passing -1 for bool is not always rejected
Problem: Passing -1 for bool is not always rejected. Solution: Check for error in a better way. (closes #12358)
This commit is contained in:
@@ -29,8 +29,10 @@ func Test_strchars()
|
||||
call assert_equal(exp[i], strcharlen(inp[i]))
|
||||
endfor
|
||||
|
||||
call assert_fails("let v=strchars('abc', [])", 'E745:')
|
||||
call assert_fails("let v=strchars('abc', 2)", 'E1023:')
|
||||
call assert_fails("call strchars('abc', 2)", ['E1023:', 'E1023:'])
|
||||
call assert_fails("call strchars('abc', -1)", ['E1023:', 'E1023:'])
|
||||
call assert_fails("call strchars('abc', {})", ['E728:', 'E728:'])
|
||||
call assert_fails("call strchars('abc', [])", ['E745:', 'E745:'])
|
||||
endfunc
|
||||
|
||||
" Test for customlist completion
|
||||
|
||||
Reference in New Issue
Block a user