patch 8.2.2945: some buffer related code is not tested
Problem: Some buffer related code is not tested.
Solution: Add a few more tests. (Yegappan Lakshmanan, closes #8320)
diff --git a/src/testdir/test_visual.vim b/src/testdir/test_visual.vim
index b368c32..51ef5ae 100644
--- a/src/testdir/test_visual.vim
+++ b/src/testdir/test_visual.vim
@@ -811,6 +811,10 @@
" reproducible if this operation is performed manually.
"call assert_equal(['aaxa', 'bbxb', 'ccxc'], getline(1, '$'))
call assert_equal(['aaxa', 'bbba', 'ccca'], getline(1, '$'))
+ " Repeat the previous test but use 'l' to move the cursor instead of '$'
+ call setline(1, ['aaa', 'bbb', 'ccc'])
+ exe "normal! gg2l\<C-V>2jA\<Left>x"
+ call assert_equal(['aaxa', 'bbxb', 'ccxc'], getline(1, '$'))
" Change a characterwise motion to a blockwise motion using CTRL-V
%d _