diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2022-07-08 17:43:05 +0800 |
|---|---|---|
| committer | zeertzjq <zeertzjq@outlook.com> | 2022-07-12 05:36:33 +0800 |
| commit | 27fd17a79cd2c51e71077bdd896635188ad711b5 (patch) | |
| tree | 7203add5f3ae1ca1dcc32334beb5f985543cb37c /src/nvim/testdir/test_arglist.vim | |
| parent | eea6a4f2a0ad089e0f92dfbc54c92d88c9fea51e (diff) | |
| download | rneovim-27fd17a79cd2c51e71077bdd896635188ad711b5.tar.gz rneovim-27fd17a79cd2c51e71077bdd896635188ad711b5.tar.bz2 rneovim-27fd17a79cd2c51e71077bdd896635188ad711b5.zip | |
vim-patch:8.2.0243: insufficient code coverage for ex_docmd.c functions
Problem: Insufficient code coverage for ex_docmd.c functions.
Solution: Add more tests. (Yegappan Lakshmanan, closes vim/vim#5618)
https://github.com/vim/vim/commit/9f6277bdde97b7767ded43a0b5a2023eb601b3b7
Cherry-pick Test_window_only() from patch 8.2.0203.
Cherry-pick a memory leak fix from patch 8.2.0399.
Diffstat (limited to 'src/nvim/testdir/test_arglist.vim')
| -rw-r--r-- | src/nvim/testdir/test_arglist.vim | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_arglist.vim b/src/nvim/testdir/test_arglist.vim index 164149476f..5caceeb958 100644 --- a/src/nvim/testdir/test_arglist.vim +++ b/src/nvim/testdir/test_arglist.vim @@ -1,5 +1,8 @@ " Test argument list commands +source shared.vim +source term_util.vim + func Reset_arglist() args a | %argd endfunc @@ -510,3 +513,17 @@ func Test_argdo() call assert_equal(['Xa.c', 'Xb.c', 'Xc.c'], l) bwipe Xa.c Xb.c Xc.c endfunc + +" Test for quiting Vim with unedited files in the argument list +func Test_quit_with_arglist() + if !CanRunVimInTerminal() + throw 'Skipped: cannot run vim in terminal' + endif + let buf = RunVimInTerminal('', {'rows': 6}) + call term_sendkeys(buf, ":args a b c\n") + call term_sendkeys(buf, ":quit\n") + call WaitForAssert({-> assert_match('^E173:', term_getline(buf, 6))}) + call StopVimInTerminal(buf) +endfunc + +" vim: shiftwidth=2 sts=2 expandtab |