diff options
Diffstat (limited to 'src/testdir/test_scroll_opt.vim')
-rw-r--r-- | src/testdir/test_scroll_opt.vim | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/testdir/test_scroll_opt.vim b/src/testdir/test_scroll_opt.vim index dd2af0125b..294da0d877 100644 --- a/src/testdir/test_scroll_opt.vim +++ b/src/testdir/test_scroll_opt.vim @@ -1018,6 +1018,8 @@ func Test_smoothscroll_page() call assert_equal(0, winsaveview().skipcol) " Half-page scrolling does not go beyond end of buffer and moves the cursor. + " Even with 'nostartofline', the correct amount of lines is scrolled. + setl nostartofline exe "norm! 0\<C-D>" call assert_equal(200, winsaveview().skipcol) call assert_equal(204, col('.')) @@ -1041,7 +1043,7 @@ func Test_smoothscroll_page() call assert_equal(204, col('.')) exe "norm! \<C-U>" call assert_equal(0, winsaveview().skipcol) - call assert_equal(1, col('.')) + call assert_equal(40, col('.')) bwipe! endfunc @@ -1059,6 +1061,11 @@ func Test_smoothscroll_next_topline() redraw call assert_equal(0, winsaveview().skipcol) + " Also when scrolling back. + exe "norm! G\<C-Y>" + redraw + call assert_equal(880, winsaveview().skipcol) + " Cursor in correct place when not in the first screenline of a buffer line. exe "norm! gg4gj20\<C-D>\<C-D>" redraw |