Mercurial > vim
comparison src/testdir/test_cmdline.vim @ 23322:68df9697667a v8.2.2206
patch 8.2.2206: :exe command line completion only works for first argument
Commit: https://github.com/vim/vim/commit/4941b5effd7f6a26583a949c92ee50276a3b43f9
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Dec 24 17:15:53 2020 +0100
patch 8.2.2206: :exe command line completion only works for first argument
Problem: :exe command line completion only works for first argument.
Solution: Skip over text if more is following. (closes https://github.com/vim/vim/issues/7546)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 24 Dec 2020 17:30:04 +0100 |
parents | 47a5349168ea |
children | 32a9d01c2a49 |
comparison
equal
deleted
inserted
replaced
23321:86d163526c2d | 23322:68df9697667a |
---|---|
669 func Test_cmdline_complete_env_variable() | 669 func Test_cmdline_complete_env_variable() |
670 let $X_VIM_TEST_COMPLETE_ENV = 'foo' | 670 let $X_VIM_TEST_COMPLETE_ENV = 'foo' |
671 call feedkeys(":edit $X_VIM_TEST_COMPLETE_E\<C-A>\<C-B>\"\<CR>", 'tx') | 671 call feedkeys(":edit $X_VIM_TEST_COMPLETE_E\<C-A>\<C-B>\"\<CR>", 'tx') |
672 call assert_match('"edit $X_VIM_TEST_COMPLETE_ENV', @:) | 672 call assert_match('"edit $X_VIM_TEST_COMPLETE_ENV', @:) |
673 unlet $X_VIM_TEST_COMPLETE_ENV | 673 unlet $X_VIM_TEST_COMPLETE_ENV |
674 endfunc | |
675 | |
676 func Test_cmdline_complete_expression() | |
677 let g:SomeVar = 'blah' | |
678 for cmd in ['exe', 'echo', 'echon', 'echomsg'] | |
679 call feedkeys(":" .. cmd .. " SomeV\<Tab>\<C-B>\"\<CR>", 'tx') | |
680 call assert_match('"' .. cmd .. ' SomeVar', @:) | |
681 call feedkeys(":" .. cmd .. " foo SomeV\<Tab>\<C-B>\"\<CR>", 'tx') | |
682 call assert_match('"' .. cmd .. ' foo SomeVar', @:) | |
683 endfor | |
684 unlet g:SomeVar | |
674 endfunc | 685 endfunc |
675 | 686 |
676 " Test for various command-line completion | 687 " Test for various command-line completion |
677 func Test_cmdline_complete_various() | 688 func Test_cmdline_complete_various() |
678 " completion for a command starting with a comment | 689 " completion for a command starting with a comment |