diff options
Diffstat (limited to 'test/old')
-rw-r--r-- | test/old/testdir/test_display.vim | 19 | ||||
-rw-r--r-- | test/old/testdir/test_scroll_opt.vim | 2 |
2 files changed, 18 insertions, 3 deletions
diff --git a/test/old/testdir/test_display.vim b/test/old/testdir/test_display.vim index a2b40521d9..e007b6f741 100644 --- a/test/old/testdir/test_display.vim +++ b/test/old/testdir/test_display.vim @@ -518,14 +518,29 @@ func Test_display_cursor_long_line() CheckScreendump let lines =<< trim END - call setline(1, ['a', 'bbbbb '->repeat(100), 'c']) + call setline(1, ['a', 'b ' .. 'bbbbb'->repeat(150), 'c']) norm $j END call writefile(lines, 'XdispCursorLongline', 'D') let buf = RunVimInTerminal('-S XdispCursorLongline', #{rows: 8}) - call VerifyScreenDump(buf, 'Test_display_cursor_long_line', {}) + call VerifyScreenDump(buf, 'Test_display_cursor_long_line_1', {}) + + " FIXME: moving the cursor above the topline does not set w_skipcol + " correctly with cpo+=n and zero scrolloff (curs_columns() extra == 1). + call term_sendkeys(buf, ":set number cpo+=n scrolloff=0\<CR>") + call term_sendkeys(buf, '$0') + call VerifyScreenDump(buf, 'Test_display_cursor_long_line_2', {}) + + " Going to the start of the line with "b" did not set w_skipcol correctly + " with 'smoothscroll'. + call term_sendkeys(buf, ":set smoothscroll\<CR>") + call term_sendkeys(buf, '$b') + call VerifyScreenDump(buf, 'Test_display_cursor_long_line_3', {}) + " Same for "ge". + call term_sendkeys(buf, '$ge') + call VerifyScreenDump(buf, 'Test_display_cursor_long_line_4', {}) call StopVimInTerminal(buf) endfunc diff --git a/test/old/testdir/test_scroll_opt.vim b/test/old/testdir/test_scroll_opt.vim index 13ef4b76df..74c2de81aa 100644 --- a/test/old/testdir/test_scroll_opt.vim +++ b/test/old/testdir/test_scroll_opt.vim @@ -502,7 +502,7 @@ func Test_smoothscroll_cursor_position() " regardless of number and cpo-=n. setl number list listchars=precedes:< cpo-=n call s:check_col_calc(5, 1, 1) - exe "normal 2|\<C-E>" + exe "normal 3|\<C-E>h" call s:check_col_calc(6, 1, 18) norm h call s:check_col_calc(5, 2, 17) |