forked from aniani/vim
patch 8.2.4676: test fails with different error
Problem: Test fails with different error. Solution: Add argument for :elseif.
This commit is contained in:
@@ -3025,7 +3025,7 @@ func Test_nested_if_else_errors()
|
||||
|
||||
" :elseif without :if
|
||||
let code =<< trim END
|
||||
elseif
|
||||
elseif 1
|
||||
END
|
||||
call writefile(code, 'Xtest')
|
||||
call AssertException(['source Xtest'], 'Vim(elseif):E582: :elseif without :if')
|
||||
@@ -3033,7 +3033,7 @@ func Test_nested_if_else_errors()
|
||||
" :elseif without :if
|
||||
let code =<< trim END
|
||||
while 1
|
||||
elseif
|
||||
elseif 1
|
||||
endwhile
|
||||
END
|
||||
call writefile(code, 'Xtest')
|
||||
@@ -3043,7 +3043,7 @@ func Test_nested_if_else_errors()
|
||||
let code =<< trim END
|
||||
try
|
||||
finally
|
||||
elseif
|
||||
elseif 1
|
||||
endtry
|
||||
END
|
||||
call writefile(code, 'Xtest')
|
||||
@@ -3052,7 +3052,7 @@ func Test_nested_if_else_errors()
|
||||
" :elseif without :if
|
||||
let code =<< trim END
|
||||
try
|
||||
elseif
|
||||
elseif 1
|
||||
endtry
|
||||
END
|
||||
call writefile(code, 'Xtest')
|
||||
@@ -3063,7 +3063,7 @@ func Test_nested_if_else_errors()
|
||||
try
|
||||
throw "a"
|
||||
catch /a/
|
||||
elseif
|
||||
elseif 1
|
||||
endtry
|
||||
END
|
||||
call writefile(code, 'Xtest')
|
||||
|
||||
Reference in New Issue
Block a user