aboutsummaryrefslogtreecommitdiff
path: root/test/functional/options/keymap_spec.lua
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/options/keymap_spec.lua')
-rw-r--r--test/functional/options/keymap_spec.lua15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/functional/options/keymap_spec.lua b/test/functional/options/keymap_spec.lua
index 43fd1eb990..7f6d623dc7 100644
--- a/test/functional/options/keymap_spec.lua
+++ b/test/functional/options/keymap_spec.lua
@@ -215,4 +215,19 @@ describe("'keymap' / :lmap", function()
feed('il')
expect('aalllaaa')
end)
+ it('does not cause recursive mappings', function()
+ command('lmap a l')
+ feed('qaila<esc>q')
+ expect('allllaaa')
+ feed('u@a')
+ expect('allllaaa')
+ end)
+ it('can handle multicharacter mappings', function()
+ command("lmap 'a x")
+ command("lmap '' '")
+ feed("qai'a''a<esc>q")
+ expect("x'alllaaa")
+ feed('u@a')
+ expect("x'alllaaa")
+ end)
end)