diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-01-25 20:48:33 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-01-25 20:48:33 +0100 |
commit | 865767126e97d9ac65e052a657b29bbc32dcb512 (patch) | |
tree | 6f6a74f88ed36f13c18f42c8308f8ddb40525bd7 /src/testdir/test_assert.vim | |
parent | 240583869ae477202494dd01ef1e8e2bac650f10 (diff) | |
download | vim-git-865767126e97d9ac65e052a657b29bbc32dcb512.tar.gz |
patch 8.1.0819: a failed assert with a long string is hard to readv8.1.0819
Problem: A failed assert with a long string is hard to read.
Solution: Shorten the assert message.
Diffstat (limited to 'src/testdir/test_assert.vim')
-rw-r--r-- | src/testdir/test_assert.vim | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/testdir/test_assert.vim b/src/testdir/test_assert.vim index fb31478aa..298a6db15 100644 --- a/src/testdir/test_assert.vim +++ b/src/testdir/test_assert.vim @@ -31,6 +31,10 @@ func Test_assert_equal() call assert_equal(1, assert_equal('bar', s)) call assert_match("Expected 'bar' but got 'foo'", v:errors[0]) call remove(v:errors, 0) + + call assert_equal('XxxxxxxxxxxxxxxxxxxxxxX', 'XyyyyyyyyyyyyyyyyyyyyyyyyyX') + call assert_match("Expected 'X\\\\\\[x occurs 21 times]X' but got 'X\\\\\\[y occurs 25 times]X'", v:errors[0]) + call remove(v:errors, 0) endfunc func Test_assert_equalfile() |