diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2023-06-27 08:55:59 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-06-27 08:55:59 +0800 |
| commit | 2e055e49a3ae27db641986650aa9e7b2b962cf63 (patch) | |
| tree | 421d42a6c3d86e11cf37af09175ccb789c069214 /test/old/testdir | |
| parent | 0ca2d11c1f473d9924c261c9dbd4e38730932bb4 (diff) | |
| parent | 116b09ac0495f07cb42a0b034622b6122d4ea0f8 (diff) | |
| download | rneovim-2e055e49a3ae27db641986650aa9e7b2b962cf63.tar.gz rneovim-2e055e49a3ae27db641986650aa9e7b2b962cf63.tar.bz2 rneovim-2e055e49a3ae27db641986650aa9e7b2b962cf63.zip | |
Merge pull request #24170 from zeertzjq/vim-9.0.1664
vim-patch:9.0.{1664,1667}: divide by zero when scrolling with 'smoothscroll' set
Diffstat (limited to 'test/old/testdir')
| -rw-r--r-- | test/old/testdir/test_scroll_opt.vim | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/old/testdir/test_scroll_opt.vim b/test/old/testdir/test_scroll_opt.vim index d7be074168..f60c0ddb59 100644 --- a/test/old/testdir/test_scroll_opt.vim +++ b/test/old/testdir/test_scroll_opt.vim @@ -836,4 +836,26 @@ func Test_smoothscroll_multi_skipcol() call StopVimInTerminal(buf) endfunc +" this was dividing by zero bug in scroll_cursor_bot +func Test_smoothscroll_zero_width_scroll_cursor_bot() + CheckScreendump + + let lines =<< trim END + silent normal yy + silent normal 19p + set cpoptions+=n + vsplit + vertical resize 0 + set foldcolumn=1 + set number + set smoothscroll + silent normal 20G + END + call writefile(lines, 'XSmoothScrollZeroBot', 'D') + let buf = RunVimInTerminal('-u NONE -S XSmoothScrollZeroBot', #{rows: 19}) + call VerifyScreenDump(buf, 'Test_smoothscroll_zero_bot', {}) + + call StopVimInTerminal(buf) +endfunc + " vim: shiftwidth=2 sts=2 expandtab |