aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir
diff options
context:
space:
mode:
authorSean Dewar <seandewar@users.noreply.github.com>2021-09-10 13:14:50 +0100
committerSean Dewar <seandewar@users.noreply.github.com>2021-09-10 15:52:07 +0100
commitb91609a70d6b7be2f067cefc178c9bb749c33b07 (patch)
tree74c345762cc6de9b8298d4aa024d5d0fe75f67ba /src/nvim/testdir
parentfd1dbb103bb78f04dd15b50f529bb12d922e98eb (diff)
downloadrneovim-b91609a70d6b7be2f067cefc178c9bb749c33b07.tar.gz
rneovim-b91609a70d6b7be2f067cefc178c9bb749c33b07.tar.bz2
rneovim-b91609a70d6b7be2f067cefc178c9bb749c33b07.zip
vim-patch:8.2.2903: cursor position wrong on wrapped line with 'signcolumn'
Problem: Cursor position wrong on wrapped line with 'signcolumn'. Solution: Don't add space for showbreak twice. (Christian Brabandt, closes vim/vim#8262) https://github.com/vim/vim/commit/a06e345af5b8261c072c95b0446e67cfda439848 Add a modeline to test_display.vim. This introduced a regression fixed by v8.2.3391.
Diffstat (limited to 'src/nvim/testdir')
-rw-r--r--src/nvim/testdir/test_display.vim18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_display.vim b/src/nvim/testdir/test_display.vim
index c702b44b88..12327f34d6 100644
--- a/src/nvim/testdir/test_display.vim
+++ b/src/nvim/testdir/test_display.vim
@@ -262,3 +262,21 @@ func Test_display_scroll_at_topline()
call StopVimInTerminal(buf)
endfunc
+
+func Test_display_linebreak_breakat()
+ new
+ vert resize 25
+ let _breakat = &breakat
+ setl signcolumn=yes linebreak breakat=) showbreak=+\
+ call setline(1, repeat('x', winwidth(0) - 2) .. ')abc')
+ let lines = ScreenLines([1, 2], 25)
+ let expected = [
+ \ ' xxxxxxxxxxxxxxxxxxxxxxx',
+ \ ' + )abc '
+ \ ]
+ call assert_equal(expected, lines)
+ %bw!
+ let &breakat=_breakat
+endfunc
+
+" vim: shiftwidth=2 sts=2 expandtab