vim-patch:partial:8.2.1183: assert_fails() checks the last error message

Problem:    assert_fails() checks the last error message.
Solution:   Check the first error, it is more relevant.  Fix all the tests
            that rely on the old behavior.

9b7bf9e98f

Skip test_listener.vim, test_textprop.vim, test_viminfo.vim.
Skip test_python2.vim: affected line fails and hasn't been ported.
Skip test_python3.vim: affected lines fail and haven't been ported.
Skip CHECK_LIST_MATERIALIZE.

Co-authored-by: Bram Moolenaar <Bram@vim.org>
This commit is contained in:
zeertzjq
2022-11-05 07:24:06 +08:00
parent a86295cd5c
commit 8b0c5de4e0
38 changed files with 144 additions and 109 deletions

View File

@@ -194,6 +194,10 @@ EXTERN int emsg_skip INIT(= 0); // don't display errors for
// expression that is skipped
EXTERN bool emsg_severe INIT(= false); // use message of next of several
// emsg() calls for throw
// used by assert_fails()
EXTERN bool emsg_assert_fails_used INIT(= false);
EXTERN char *emsg_assert_fails_msg INIT(= NULL);
EXTERN bool did_endif INIT(= false); // just had ":endif"
EXTERN dict_T vimvardict; // Dictionary with v: variables
EXTERN dict_T globvardict; // Dictionary with g: variables