From cc58ec9a801510fe77edb34e02b0635c4f24f924 Mon Sep 17 00:00:00 2001 From: Matthew Malcomson Date: Thu, 1 Jun 2017 09:20:56 +0100 Subject: Update documentation Update vim_diff.txt with :lmap differences, update documentation on 'keymap', and add tests. The tests added are to demonstrate the behaviour specified in the documentation of :loadkeymap. --- test/functional/options/keymap_spec.lua | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'test') 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('qailaq') + expect('allllaaa') + feed('u@a') + expect('allllaaa') + end) + it('can handle multicharacter mappings', function() + command("lmap 'a x") + command("lmap '' '") + feed("qai'a''aq") + expect("x'alllaaa") + feed('u@a') + expect("x'alllaaa") + end) end) -- cgit