mirror of
https://github.com/neovim/neovim.git
synced 2025-10-03 08:28:34 +00:00
vim-patch:8.2.0325: ex_getln.c code not covered by tests
Problem: Ex_getln.c code not covered by tests.
Solution: Add a few more tests. (Yegappan Lakshmanan, closes vim/vim#5702)
578fe947e3
Cherry-pick Test_Ex_global() from patch 8.2.0293.
Test_rightleftcmd() fails if incsearch is enabled, so disable it.
This commit is contained in:
@@ -1218,6 +1218,16 @@ func Test_input_func()
|
||||
call assert_fails("call input('F:', '', [])", 'E730:')
|
||||
endfunc
|
||||
|
||||
" Test for the inputdialog() function
|
||||
func Test_inputdialog()
|
||||
CheckNotGui
|
||||
|
||||
call feedkeys(":let v=inputdialog('Q:', 'xx', 'yy')\<CR>\<CR>", 'xt')
|
||||
call assert_equal('xx', v)
|
||||
call feedkeys(":let v=inputdialog('Q:', 'xx', 'yy')\<CR>\<Esc>", 'xt')
|
||||
call assert_equal('yy', v)
|
||||
endfunc
|
||||
|
||||
" Test for inputlist()
|
||||
func Test_inputlist()
|
||||
call feedkeys(":let c = inputlist(['Select color:', '1. red', '2. green', '3. blue'])\<cr>1\<cr>", 'tx')
|
||||
|
Reference in New Issue
Block a user