diff options
| author | James McCoy <jamessan@jamessan.com> | 2020-08-08 08:57:35 -0400 |
|---|---|---|
| committer | James McCoy <jamessan@jamessan.com> | 2020-08-08 08:57:35 -0400 |
| commit | 840c12c10741d8f70e1787534fb6ea6d2b70edee (patch) | |
| tree | f89ad27acbbf0b36db7ac08eeae0b8362da1fabb /src/nvim/testdir/test_listlbr.vim | |
| parent | e813ec79c201c85c5af3b10c051ae92ab5cb8606 (diff) | |
| parent | f26df8bb66158baacb79c79822babaf137607cd6 (diff) | |
| download | rneovim-840c12c10741d8f70e1787534fb6ea6d2b70edee.tar.gz rneovim-840c12c10741d8f70e1787534fb6ea6d2b70edee.tar.bz2 rneovim-840c12c10741d8f70e1787534fb6ea6d2b70edee.zip | |
Merge remote-tracking branch 'upstream/master' into libcallnr
Diffstat (limited to 'src/nvim/testdir/test_listlbr.vim')
| -rw-r--r-- | src/nvim/testdir/test_listlbr.vim | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_listlbr.vim b/src/nvim/testdir/test_listlbr.vim index d28dbc444c..cdc5e4cc7c 100644 --- a/src/nvim/testdir/test_listlbr.vim +++ b/src/nvim/testdir/test_listlbr.vim @@ -103,6 +103,37 @@ func Test_linebreak_with_conceal() call s:close_windows() endfunc +func Test_linebreak_with_visual_operations() + call s:test_windows() + let line = '1234567890 2234567890 3234567890' + call setline(1, line) + + " yank + exec "norm! ^w\<C-V>ey" + call assert_equal('2234567890', @@) + exec "norm! w\<C-V>ey" + call assert_equal('3234567890', @@) + + " increment / decrement + exec "norm! ^w\<C-V>\<C-A>w\<C-V>\<C-X>" + call assert_equal('1234567890 3234567890 2234567890', getline(1)) + + " replace + exec "norm! ^w\<C-V>3lraw\<C-V>3lrb" + call assert_equal('1234567890 aaaa567890 bbbb567890', getline(1)) + + " tilde + exec "norm! ^w\<C-V>2l~w\<C-V>2l~" + call assert_equal('1234567890 AAAa567890 BBBb567890', getline(1)) + + " delete and insert + exec "norm! ^w\<C-V>3lc2345\<Esc>w\<C-V>3lc3456\<Esc>" + call assert_equal('1234567890 2345567890 3456567890', getline(1)) + call assert_equal('BBBb', @@) + + call s:close_windows() +endfunc + func Test_virtual_block() call s:test_windows('setl sbr=+') call setline(1, [ |