diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-11-06 12:43:05 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-06 12:43:05 +0800 |
commit | 850d7146fc7fb57691641c729d5580b834cd7dd2 (patch) | |
tree | 0ef520e3ec0f5d060c42deeca52ffc4d56b31633 /test/functional/api/vim_spec.lua | |
parent | eb55eba7e5b422301c50088623e60514a843ab08 (diff) | |
download | rneovim-850d7146fc7fb57691641c729d5580b834cd7dd2.tar.gz rneovim-850d7146fc7fb57691641c729d5580b834cd7dd2.tar.bz2 rneovim-850d7146fc7fb57691641c729d5580b834cd7dd2.zip |
fix(paste): feed keys as typed in cmdline mode (#20959)
Diffstat (limited to 'test/functional/api/vim_spec.lua')
-rw-r--r-- | test/functional/api/vim_spec.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/functional/api/vim_spec.lua b/test/functional/api/vim_spec.lua index af6cee7e90..114413365f 100644 --- a/test/functional/api/vim_spec.lua +++ b/test/functional/api/vim_spec.lua @@ -1108,6 +1108,14 @@ describe('API', function() nvim('paste', 'a', true, -1) eq('a', funcs.getcmdline()) end) + it('pasted text is saved in cmdline history when <CR> comes from mapping #20957', function() + command('cnoremap <CR> <CR>') + feed(':') + nvim('paste', 'echo', true, -1) + eq('', funcs.histget(':')) + feed('<CR>') + eq('echo', funcs.histget(':')) + end) it('pasting with empty last chunk in Cmdline mode', function() local screen = Screen.new(20, 4) screen:attach() |