diff options
author | zeertzjq <zeertzjq@outlook.com> | 2025-03-30 07:12:01 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-03-30 07:12:01 +0800 |
commit | 99529577cc9f5229cbb3dac8ab4782bd43094102 (patch) | |
tree | 426e4281a3123b9ada2be680721e91ba82c621ab /test/functional | |
parent | 5f9f5bc04d0bec0fbf100dd5a0de2b38daf882fb (diff) | |
download | rneovim-99529577cc9f5229cbb3dac8ab4782bd43094102.tar.gz rneovim-99529577cc9f5229cbb3dac8ab4782bd43094102.tar.bz2 rneovim-99529577cc9f5229cbb3dac8ab4782bd43094102.zip |
fix(api): use E226 instead of E227 for duplicate abbreviation (#33159)
Diffstat (limited to 'test/functional')
-rw-r--r-- | test/functional/api/keymap_spec.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/functional/api/keymap_spec.lua b/test/functional/api/keymap_spec.lua index 73dae0dd60..acaccee4e5 100644 --- a/test/functional/api/keymap_spec.lua +++ b/test/functional/api/keymap_spec.lua @@ -814,6 +814,12 @@ describe('nvim_set_keymap, nvim_del_keymap', function() 'E227: Mapping already exists for <tab>', pcall_err(api.nvim_set_keymap, 'n', '<tab>', 'rhs', { unique = true }) ) + + api.nvim_set_keymap('ia', 'lhs', 'rhs', {}) + eq( + 'E226: Abbreviation already exists for lhs', + pcall_err(api.nvim_set_keymap, 'ia', 'lhs', 'rhs', { unique = true }) + ) end) it('can set <expr> mappings whose RHS change dynamically', function() |