diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-09-24 21:16:50 +0800 |
---|---|---|
committer | zeertzjq <zeertzjq@outlook.com> | 2022-09-24 21:17:03 +0800 |
commit | 0c77dba9a46765c7a769090ae21433efea5bda00 (patch) | |
tree | 6a864981cd974b910cca1e387da8cf8ebcdda2be /src | |
parent | 57b731818d3d54dacdace081f6db4a8ce813173d (diff) | |
download | rneovim-0c77dba9a46765c7a769090ae21433efea5bda00.tar.gz rneovim-0c77dba9a46765c7a769090ae21433efea5bda00.tar.bz2 rneovim-0c77dba9a46765c7a769090ae21433efea5bda00.zip |
vim-patch:9.0.0572: insert complete tests leave a mapping behind
Problem: Insert complete tests leave a mapping behind.
Solution: Use a buffer-local mapping. (closes vim/vim#11211)
https://github.com/vim/vim/commit/75f4bafabdcc6bce5cf3e09fee29c634bf102c17
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/testdir/test_ins_complete.vim | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/nvim/testdir/test_ins_complete.vim b/src/nvim/testdir/test_ins_complete.vim index 0810bd4adc..f706322a85 100644 --- a/src/nvim/testdir/test_ins_complete.vim +++ b/src/nvim/testdir/test_ins_complete.vim @@ -704,8 +704,8 @@ endfunc " Test for using complete() with completeopt+=longest func Test_complete_with_longest() - inoremap <f3> <cmd>call complete(1, ["iaax", "iaay", "iaaz"])<cr> new + inoremap <buffer> <f3> <cmd>call complete(1, ["iaax", "iaay", "iaaz"])<cr> " default: insert first match set completeopt& @@ -719,6 +719,7 @@ func Test_complete_with_longest() exe "normal Aa\<f3>\<esc>" call assert_equal('iaa', getline(1)) set completeopt& + bwipe! endfunc @@ -1276,7 +1277,7 @@ endfunc " A mapping is not used for the key after CTRL-X. func Test_no_mapping_for_ctrl_x_key() new - inoremap <C-K> <Cmd>let was_mapped = 'yes'<CR> + inoremap <buffer> <C-K> <Cmd>let was_mapped = 'yes'<CR> setlocal dictionary=README.txt call feedkeys("aexam\<C-X>\<C-K> ", 'xt') call assert_equal('example ', getline(1)) |