aboutsummaryrefslogtreecommitdiff
path: root/test/functional/legacy/mapping_spec.lua
diff options
context:
space:
mode:
authorFlorian Walch <florian@fwalch.com>2014-12-26 16:49:44 +0100
committerFlorian Walch <florian@fwalch.com>2014-12-26 16:54:24 +0100
commite27460b60cb3d725ecfe8ba34438642fdb174280 (patch)
tree99949dede641e5350a20fe2f6319af66117c8b85 /test/functional/legacy/mapping_spec.lua
parentcab88790bcf8fa4ae5a634b1ccaf84d337fa47e2 (diff)
downloadrneovim-e27460b60cb3d725ecfe8ba34438642fdb174280.tar.gz
rneovim-e27460b60cb3d725ecfe8ba34438642fdb174280.tar.bz2
rneovim-e27460b60cb3d725ecfe8ba34438642fdb174280.zip
vim-patch:7.4.552
Problem: Langmap applies to Insert mode expression mappings. Solution: Check for Insert mode. (Daniel Hahler) https://code.google.com/p/vim/source/detail?r=v7-4-552
Diffstat (limited to 'test/functional/legacy/mapping_spec.lua')
-rw-r--r--test/functional/legacy/mapping_spec.lua13
1 files changed, 12 insertions, 1 deletions
diff --git a/test/functional/legacy/mapping_spec.lua b/test/functional/legacy/mapping_spec.lua
index 46d29d1692..1451b268c5 100644
--- a/test/functional/legacy/mapping_spec.lua
+++ b/test/functional/legacy/mapping_spec.lua
@@ -18,9 +18,20 @@ describe('mapping', function()
execute('inoreab чкпр vim')
feed('GAчкпр <cr><esc>')
+ -- langmap should not get remapped in insert mode.
+ execute('inoremap { FAIL_ilangmap')
+ execute('set langmap=+{ langnoremap')
+ feed('o+<esc>')
+
+ -- expr mapping with langmap.
+ execute('inoremap <expr> { "FAIL_iexplangmap"')
+ feed('o+<esc>')
+
-- Assert buffer contents.
expect([[
test starts here:
- vim]])
+ vim
+ +
+ +]])
end)
end)