summaryrefslogtreecommitdiff
path: root/src/testdir/test_match.vim
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-10-16 14:35:48 +0200
committerBram Moolenaar <Bram@vim.org>2016-10-16 14:35:48 +0200
commit8507747600bddfd6a68aed057840856bf5548e61 (patch)
tree896cf0dc5549bf62849d79a11ba2df379a5644c5 /src/testdir/test_match.vim
parent156919f99afd1ac11d19d4270afbc1afb7245640 (diff)
downloadvim-git-8507747600bddfd6a68aed057840856bf5548e61.tar.gz
patch 8.0.0040v8.0.0040
Problem: Whole line highlighting with matchaddpos() does not work. Solution: Check for zero length. (Hirohito Higashi)
Diffstat (limited to 'src/testdir/test_match.vim')
-rw-r--r--src/testdir/test_match.vim8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/testdir/test_match.vim b/src/testdir/test_match.vim
index 3b20d5d43..9398ef2f2 100644
--- a/src/testdir/test_match.vim
+++ b/src/testdir/test_match.vim
@@ -191,7 +191,15 @@ func Test_matchaddpos()
call assert_equal(screenattr(2,2), screenattr(1,7))
call assert_notequal(screenattr(2,2), screenattr(1,8))
+ call clearmatches()
+ call matchaddpos('Error', [[1], [2,2]])
+ redraw!
+ call assert_equal(screenattr(2,2), screenattr(1,1))
+ call assert_equal(screenattr(2,2), screenattr(1,10))
+ call assert_notequal(screenattr(2,2), screenattr(1,11))
+
nohl
+ call clearmatches()
syntax off
set hlsearch&
endfunc