aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2023-05-04 21:00:46 +0800
committerzeertzjq <zeertzjq@outlook.com>2023-05-05 19:43:10 +0800
commit0a3a2132d43be3a376214f75157d4d2b1340311e (patch)
tree07b5b9ec75c001c89733474f51b12a61df94453f /test
parentd9f0d2da4d29847542072099f103e7248fcacaab (diff)
downloadrneovim-0a3a2132d43be3a376214f75157d4d2b1340311e.tar.gz
rneovim-0a3a2132d43be3a376214f75157d4d2b1340311e.tar.bz2
rneovim-0a3a2132d43be3a376214f75157d4d2b1340311e.zip
vim-patch:8.2.1953: Vim9: extra "unknown" error after other error
Problem: Vim9: extra "unknown" error after other error. Solution: Restore did_emsg count after EXEC instruction. (closes vim/vim#7254) Improve error message from assert_fails() https://github.com/vim/vim/commit/631e8f93458b102091d54c502f489c03e454d4da Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'test')
-rw-r--r--test/old/testdir/test_assert.vim12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/old/testdir/test_assert.vim b/test/old/testdir/test_assert.vim
index 62b2e5d7ab..5fd0103d27 100644
--- a/test/old/testdir/test_assert.vim
+++ b/test/old/testdir/test_assert.vim
@@ -6,11 +6,11 @@ func Test_assert_false()
call assert_equal(0, v:false->assert_false())
call assert_equal(1, assert_false(123))
- call assert_match("Expected False but got 123", v:errors[0])
+ call assert_match("Expected 'False' but got 123", v:errors[0])
call remove(v:errors, 0)
call assert_equal(1, 123->assert_false())
- call assert_match("Expected False but got 123", v:errors[0])
+ call assert_match("Expected 'False' but got 123", v:errors[0])
call remove(v:errors, 0)
endfunc
@@ -21,11 +21,11 @@ func Test_assert_true()
call assert_equal(0, v:true->assert_true())
call assert_equal(1, assert_true(0))
- call assert_match("Expected True but got 0", v:errors[0])
+ call assert_match("Expected 'True' but got 0", v:errors[0])
call remove(v:errors, 0)
call assert_equal(1, 0->assert_true())
- call assert_match("Expected True but got 0", v:errors[0])
+ call assert_match("Expected 'True' but got 0", v:errors[0])
call remove(v:errors, 0)
endfunc
@@ -228,11 +228,11 @@ func Test_assert_fail_fails()
call remove(v:errors, 0)
call assert_equal(1, assert_fails('xxx', ['E9876']))
- call assert_match("Expected \\['E9876'\\] but got 'E492:", v:errors[0])
+ call assert_match("Expected 'E9876' but got 'E492:", v:errors[0])
call remove(v:errors, 0)
call assert_equal(1, assert_fails('xxx', ['E492:', 'E9876']))
- call assert_match("Expected \\['E492:', 'E9876'\\] but got 'E492:", v:errors[0])
+ call assert_match("Expected 'E9876' but got 'E492:", v:errors[0])
call remove(v:errors, 0)
call assert_equal(1, assert_fails('echo', '', 'echo command'))