comparison src/testdir/test_cmdline.vim @ 31966:3f39349c5107 v9.0.1315

patch 9.0.1315: escaping for completion of map command not properly tested Commit: https://github.com/vim/vim/commit/c3a26c6bff666a368b0a22d35d2e00aa62770f8c Author: zeertzjq <zeertzjq@outlook.com> Date: Fri Feb 17 16:40:20 2023 +0000 patch 9.0.1315: escaping for completion of map command not properly tested Problem: Escaping for completion of map command not properly tested. Solution: Add a few test cases. (closes https://github.com/vim/vim/issues/12009)
author Bram Moolenaar <Bram@vim.org>
date Fri, 17 Feb 2023 17:45:05 +0100
parents 9fc3b3928ad5
children a5b5d8df5763
comparison
equal deleted inserted replaced
31965:b6a1e17f049d 31966:3f39349c5107
325 call assert_equal('"map ,g', getreg(':')) 325 call assert_equal('"map ,g', getreg(':'))
326 call feedkeys(":map <L\<Tab>\<Home>\"\<CR>", 'xt') 326 call feedkeys(":map <L\<Tab>\<Home>\"\<CR>", 'xt')
327 call assert_equal('"map <Left>', getreg(':')) 327 call assert_equal('"map <Left>', getreg(':'))
328 call feedkeys(":map <A-Left>\<Tab>\<Home>\"\<CR>", 'xt') 328 call feedkeys(":map <A-Left>\<Tab>\<Home>\"\<CR>", 'xt')
329 call assert_equal("\"map <A-Left>\<Tab>", getreg(':')) 329 call assert_equal("\"map <A-Left>\<Tab>", getreg(':'))
330 call feedkeys(":map <M-Left>\<Tab>\<Home>\"\<CR>", 'xt')
331 call assert_equal("\"map <M-Left>x", getreg(':'))
330 unmap ,f 332 unmap ,f
331 unmap ,g 333 unmap ,g
332 unmap <Left> 334 unmap <Left>
333 unmap <A-Left>x 335 unmap <A-Left>x
334 336
335 set cpo-=< cpo-=B cpo-=k 337 set cpo-=< cpo-=k
336 map <Left> left 338 map <Left> left
337 call feedkeys(":map <L\<Tab>\<Home>\"\<CR>", 'xt') 339 call feedkeys(":map <L\<Tab>\<Home>\"\<CR>", 'xt')
338 call assert_equal('"map <Left>', getreg(':')) 340 call assert_equal('"map <Left>', getreg(':'))
339 call feedkeys(":map <M\<Tab>\<Home>\"\<CR>", 'xt') 341 call feedkeys(":map <M\<Tab>\<Home>\"\<CR>", 'xt')
340 call assert_equal("\"map <M\<Tab>", getreg(':')) 342 call assert_equal("\"map <M\<Tab>", getreg(':'))
343 call feedkeys(":map \<C-V>\<C-V><M\<Tab>\<Home>\"\<CR>", 'xt')
344 call assert_equal("\"map \<C-V><Middle>x", getreg(':'))
341 unmap <Left> 345 unmap <Left>
342 346
343 set cpo+=< 347 set cpo+=<
344 map <Left> left 348 map <Left> left
345 exe "set t_k6=\<Esc>[17~" 349 exe "set t_k6=\<Esc>[17~"