diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2022-05-10 07:38:44 +0800 |
|---|---|---|
| committer | zeertzjq <zeertzjq@outlook.com> | 2022-05-10 07:59:43 +0800 |
| commit | 406c2e35b3efb72aac3fb7c174253b3397b77eb1 (patch) | |
| tree | f7641086a722d24fbc2393266b066ce80d9d6082 /src/nvim/testdir | |
| parent | 9aa5647e686e5420e5b9b51828ec7d55631f98ed (diff) | |
| download | rneovim-406c2e35b3efb72aac3fb7c174253b3397b77eb1.tar.gz rneovim-406c2e35b3efb72aac3fb7c174253b3397b77eb1.tar.bz2 rneovim-406c2e35b3efb72aac3fb7c174253b3397b77eb1.zip | |
vim-patch:8.2.4929: off-by-one error in in statusline item
Problem: Off-by-one error in in statusline item.
Solution: Subtrace one less. (closes vim/vim#10394, closes vim/vim#5599)
https://github.com/vim/vim/commit/57ff52677bf5ba1651281ffe40505df8feba4a36
Diffstat (limited to 'src/nvim/testdir')
| -rw-r--r-- | src/nvim/testdir/test_statusline.vim | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/src/nvim/testdir/test_statusline.vim b/src/nvim/testdir/test_statusline.vim index 492d09c645..8579457d9f 100644 --- a/src/nvim/testdir/test_statusline.vim +++ b/src/nvim/testdir/test_statusline.vim @@ -461,7 +461,6 @@ func Test_statusline_removed_group() call writefile(lines, 'XTest_statusline') let buf = RunVimInTerminal('-S XTest_statusline', {'rows': 10, 'cols': 50}) - call term_wait(buf, 100) call VerifyScreenDump(buf, 'Test_statusline_1', {}) " clean up @@ -535,4 +534,22 @@ func Test_statusline_verylong_filename() bwipe! endfunc +func Test_statusline_highlight_truncate() + CheckScreendump + + let lines =<< trim END + set laststatus=2 + hi! link User1 Directory + hi! link User2 ErrorMsg + set statusline=%.5(%1*ABC%2*DEF%1*GHI%) + END + call writefile(lines, 'XTest_statusline') + + let buf = RunVimInTerminal('-S XTest_statusline', {'rows': 6}) + call VerifyScreenDump(buf, 'Test_statusline_hl', {}) + + call StopVimInTerminal(buf) + call delete('XTest_statusline') +endfunc + " vim: shiftwidth=2 sts=2 expandtab |