Mercurial > vim
diff src/testdir/test_diffmode.vim @ 25517:b04e76e66128 v8.2.3295
patch 8.2.3295: 'cursorline' should not apply to 'breakindent'
Commit: https://github.com/vim/vim/commit/4f33bc20d7d5444e44d13f954e8219ad1abd26ef
Author: zeertzjq <zeertzjq@outlook.com>
Date: Thu Aug 5 17:57:02 2021 +0200
patch 8.2.3295: 'cursorline' should not apply to 'breakindent'
Problem: 'cursorline' should not apply to 'breakindent'.
Solution: Make 'cursorline' apply to 'breakindent' and 'showbreak'
consistently. (closes #8684)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 05 Aug 2021 18:00:05 +0200 |
parents | 13812db714fa |
children | d3f992bc6ef8 |
line wrap: on
line diff
--- a/src/testdir/test_diffmode.vim +++ b/src/testdir/test_diffmode.vim @@ -1018,6 +1018,37 @@ func Test_diff_with_cursorline() call delete('Xtest_diff_cursorline') endfunc +func Test_diff_with_cursorline_breakindent() + CheckScreendump + + call writefile([ + \ 'hi CursorLine ctermbg=red ctermfg=white', + \ 'set noequalalways wrap diffopt=followwrap cursorline breakindent', + \ '50vnew', + \ 'call setline(1, [" "," "," "," "])', + \ 'exe "norm 20Afoo\<Esc>j20Afoo\<Esc>j20Afoo\<Esc>j20Abar\<Esc>"', + \ 'vnew', + \ 'call setline(1, [" "," "," "," "])', + \ 'exe "norm 20Abee\<Esc>j20Afoo\<Esc>j20Afoo\<Esc>j20Abaz\<Esc>"', + \ 'windo diffthis', + \ '2wincmd w', + \ ], 'Xtest_diff_cursorline_breakindent') + let buf = RunVimInTerminal('-S Xtest_diff_cursorline_breakindent', {}) + + call term_sendkeys(buf, "gg0") + call VerifyScreenDump(buf, 'Test_diff_with_cul_bri_01', {}) + call term_sendkeys(buf, "j") + call VerifyScreenDump(buf, 'Test_diff_with_cul_bri_02', {}) + call term_sendkeys(buf, "j") + call VerifyScreenDump(buf, 'Test_diff_with_cul_bri_03', {}) + call term_sendkeys(buf, "j") + call VerifyScreenDump(buf, 'Test_diff_with_cul_bri_04', {}) + + " clean up + call StopVimInTerminal(buf) + call delete('Xtest_diff_cursorline_breakindent') +endfunc + func Test_diff_with_syntax() CheckScreendump