forked from aniani/vim
patch 8.2.0275: some Ex code not covered by tests
Problem: Some Ex code not covered by tests. Solution: Add test cases. (Yegappan Lakshmanan, closes #5659)
This commit is contained in:
@@ -519,6 +519,20 @@ func Test_quit_with_arglist()
|
||||
call term_sendkeys(buf, ":quit\n")
|
||||
call WaitForAssert({-> assert_match('^E173:', term_getline(buf, 6))})
|
||||
call StopVimInTerminal(buf)
|
||||
|
||||
" Try :confirm quit with unedited files in arglist
|
||||
let buf = RunVimInTerminal('', {'rows': 6})
|
||||
call term_sendkeys(buf, ":set nomore\n")
|
||||
call term_sendkeys(buf, ":args a b c\n")
|
||||
call term_sendkeys(buf, ":confirm quit\n")
|
||||
call WaitForAssert({-> assert_match('^\[Y\]es, (N)o: *$',
|
||||
\ term_getline(buf, 6))})
|
||||
call term_sendkeys(buf, "N")
|
||||
call term_sendkeys(buf, ":confirm quit\n")
|
||||
call WaitForAssert({-> assert_match('^\[Y\]es, (N)o: *$',
|
||||
\ term_getline(buf, 6))})
|
||||
call term_sendkeys(buf, "Y")
|
||||
call StopVimInTerminal(buf)
|
||||
endfunc
|
||||
|
||||
" vim: shiftwidth=2 sts=2 expandtab
|
||||
|
||||
Reference in New Issue
Block a user