diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-08-19 20:19:48 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-08-19 20:19:48 +0200 |
commit | 9dc1917f42b23277e143fc58bbe27482b0b76bad (patch) | |
tree | de77449754a2aef749915aa6929ff1f2138f90ea /src/testdir/test_display.vim | |
parent | a7c4e747639ad7642cd50ed577ff4c93db200df4 (diff) | |
download | vim-git-9dc1917f42b23277e143fc58bbe27482b0b76bad.tar.gz |
patch 8.2.1488: text does not scroll when inserting above first linev8.2.1488
Problem: Text does not scroll when inserting above first line.
Solution: Adjust off-by-one error. (Ken Takata, closes #6739)
Diffstat (limited to 'src/testdir/test_display.vim')
-rw-r--r-- | src/testdir/test_display.vim | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/testdir/test_display.vim b/src/testdir/test_display.vim index 97b0a9e88..49d0d8c04 100644 --- a/src/testdir/test_display.vim +++ b/src/testdir/test_display.vim @@ -245,4 +245,16 @@ func Test_visual_block_scroll() call delete(filename) endfunc +func Test_display_scroll_at_topline() + CheckScreendump + + let buf = RunVimInTerminal('', #{cols: 20}) + call term_sendkeys(buf, ":call setline(1, repeat('a', 21))\<CR>") + call term_wait(buf) + call term_sendkeys(buf, "O\<Esc>") + call VerifyScreenDump(buf, 'Test_display_scroll_at_topline', #{rows: 4}) + + call StopVimInTerminal(buf) +endfunc + " vim: shiftwidth=2 sts=2 expandtab |