summaryrefslogtreecommitdiff
path: root/src/testdir/test_textprop.vim
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2023-02-11 13:49:01 +0000
committerBram Moolenaar <Bram@vim.org>2023-02-11 13:49:01 +0000
commit9d9a20ee8799bafe9caac616fef11b7a26db6a8d (patch)
tree9234d5ca9e9e2c94943c650d24aaa39509bd2502 /src/testdir/test_textprop.vim
parent3ec78f973fdaec2cea8e036ed38037b2fe40670b (diff)
downloadvim-git-9.0.1301.tar.gz
patch 9.0.1301: virtual text below empty line not displayedv9.0.1301
Problem: Virtual text below empty line not displayed. Solution: Adjust flags and computations. (closes #11959)
Diffstat (limited to 'src/testdir/test_textprop.vim')
-rw-r--r--src/testdir/test_textprop.vim22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/testdir/test_textprop.vim b/src/testdir/test_textprop.vim
index e00bad6d3..b628c8215 100644
--- a/src/testdir/test_textprop.vim
+++ b/src/testdir/test_textprop.vim
@@ -2779,6 +2779,28 @@ func Test_prop_with_text_below_after_empty()
call StopVimInTerminal(buf)
endfunc
+func Test_prop_with_text_above_below_empty()
+ CheckRunVimInTerminal
+
+ let lines =<< trim END
+ setlocal number
+ call setline(1, ['11111111', '', '333333333', '', '55555555555'])
+
+ let vt = 'test'
+ call prop_type_add(vt, {'highlight': 'ToDo'})
+ for ln in range(1, line('$'))
+ call prop_add(ln, 0, {'type': vt, 'text': '---', 'text_align': 'above'})
+ call prop_add(ln, 0, {'type': vt, 'text': '+++', 'text_align': 'below'})
+ endfor
+ normal G
+ END
+ call writefile(lines, 'XscriptPropAboveBelowEmpty', 'D')
+ let buf = RunVimInTerminal('-S XscriptPropAboveBelowEmpty', #{rows: 16, cols: 60})
+ call VerifyScreenDump(buf, 'Test_prop_above_below_empty_1', {})
+
+ call StopVimInTerminal(buf)
+endfunc
+
func Test_prop_with_text_below_after_match()
CheckRunVimInTerminal