diff options
| author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2021-02-10 20:56:54 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-02-10 20:56:54 -0500 |
| commit | 1aec5ba85e97889c792253424c5de9c12ddd6cf4 (patch) | |
| tree | 62c78074f611cb812eb630f6e1c88eeabeae06bd /src/nvim/testdir/test_arglist.vim | |
| parent | 61aea004d7101e138794a337c03ef00a6b3994e6 (diff) | |
| parent | 81b4c881302640747de39f805312966c541acc47 (diff) | |
| download | rneovim-1aec5ba85e97889c792253424c5de9c12ddd6cf4.tar.gz rneovim-1aec5ba85e97889c792253424c5de9c12ddd6cf4.tar.bz2 rneovim-1aec5ba85e97889c792253424c5de9c12ddd6cf4.zip | |
Merge pull request #13908 from janlazo/vim-8.2.2489
vim-patch:8.1.0341,8.2.{2489,2490,2492,2495,2496}
Diffstat (limited to 'src/nvim/testdir/test_arglist.vim')
| -rw-r--r-- | src/nvim/testdir/test_arglist.vim | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_arglist.vim b/src/nvim/testdir/test_arglist.vim index 92fedf9bfb..a1ef8325ec 100644 --- a/src/nvim/testdir/test_arglist.vim +++ b/src/nvim/testdir/test_arglist.vim @@ -80,6 +80,24 @@ func Test_argadd() call assert_equal(0, len(argv())) endfunc +func Test_argadd_empty_curbuf() + new + let curbuf = bufnr('%') + call writefile(['test', 'Xargadd'], 'Xargadd') + " must not re-use the current buffer. + argadd Xargadd + call assert_equal(curbuf, bufnr('%')) + call assert_equal('', bufname('%')) + call assert_equal(1, line('$')) + rew + call assert_notequal(curbuf, bufnr('%')) + call assert_equal('Xargadd', bufname('%')) + call assert_equal(2, line('$')) + + %argd + bwipe! +endfunc + func Init_abc() args a b c next |