diff options
author | Rob Pilling <robpilling@gmail.com> | 2022-12-23 19:06:04 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-12-23 19:06:04 +0000 |
commit | e86190e7c1297da29d0fc2415fdeca5ecae8d2ba (patch) | |
tree | af6d793030ca6c8c5f785d30b0637b910cb6fde2 /src/testdir/test_global.vim | |
parent | f54cedd6763e7727b4bfaeb34bb7c365a17675eb (diff) |
patch 9.0.1092: search error message doesn't show used patternv9.0.1092
Problem: Search error message doesn't show used pattern.
Solution: Pass the actually used pattern to where the error message is
given. (Rob Pilling, closes #11742)
Diffstat (limited to 'src/testdir/test_global.vim')
-rw-r--r-- | src/testdir/test_global.vim | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/testdir/test_global.vim b/src/testdir/test_global.vim index 1c76642a18..34857b2555 100644 --- a/src/testdir/test_global.vim +++ b/src/testdir/test_global.vim @@ -92,6 +92,18 @@ func Test_global_print() close! endfunc +func Test_global_empty_pattern() + " populate history + silent g/hello/ + + redir @a + g// + redir END + + call assert_match('Pattern not found: hello', @a) + " ^~~~~ this was previously empty +endfunc + " Test for global command with newline character func Test_global_newline() new |