-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
patch 8.0.0724: the message for yanking doesn't indicate the register
Problem: The message for yanking doesn't indicate the register. Solution: Show the register name in the "N lines yanked" message. (Lemonboy, closes vim#1803, closes vim#1809)
- Loading branch information
Showing
5 changed files
with
45 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
|
||
func Test_yank_shows_register() | ||
enew | ||
set report=0 | ||
call setline(1, ['foo', 'bar']) | ||
" Line-wise | ||
exe 'norm! yy' | ||
call assert_equal('1 line yanked', v:statusmsg) | ||
exe 'norm! "zyy' | ||
call assert_equal('1 line yanked into "z', v:statusmsg) | ||
exe 'norm! yj' | ||
call assert_equal('2 lines yanked', v:statusmsg) | ||
exe 'norm! "zyj' | ||
call assert_equal('2 lines yanked into "z', v:statusmsg) | ||
|
||
" Block-wise | ||
exe "norm! \<C-V>y" | ||
call assert_equal('block of 1 line yanked', v:statusmsg) | ||
exe "norm! \<C-V>\"zy" | ||
call assert_equal('block of 1 line yanked into "z', v:statusmsg) | ||
exe "norm! \<C-V>jy" | ||
call assert_equal('block of 2 lines yanked', v:statusmsg) | ||
exe "norm! \<C-V>j\"zy" | ||
call assert_equal('block of 2 lines yanked into "z', v:statusmsg) | ||
|
||
bwipe! | ||
endfunc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters