diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-10-15 22:06:06 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-10-15 22:06:06 +0100 |
commit | db4c94788ad70118fa1ccc5fbc821757350ac771 (patch) | |
tree | 2e08a8a678c55470cb7239c0857678e7a5622ce8 /src/testdir/test_winbuf_close.vim | |
parent | 5b148ef2628251b2d79f78c65a614f8aca404329 (diff) | |
download | vim-git-db4c94788ad70118fa1ccc5fbc821757350ac771.tar.gz |
patch 9.0.0769: too many delete() calls in testsv9.0.0769
Problem: Too many delete() calls in tests.
Solution: Use deferred delete where possible.
Diffstat (limited to 'src/testdir/test_winbuf_close.vim')
-rw-r--r-- | src/testdir/test_winbuf_close.vim | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/testdir/test_winbuf_close.vim b/src/testdir/test_winbuf_close.vim index 2530be063..17e31e49d 100644 --- a/src/testdir/test_winbuf_close.vim +++ b/src/testdir/test_winbuf_close.vim @@ -12,9 +12,9 @@ func Test_winbuf_close() enew | only - call writefile(['testtext 1'], 'Xtest1') - call writefile(['testtext 2'], 'Xtest2') - call writefile(['testtext 3'], 'Xtest3') + call writefile(['testtext 1'], 'Xtest1', 'D') + call writefile(['testtext 2'], 'Xtest2', 'D') + call writefile(['testtext 3'], 'Xtest3', 'D') next! Xtest1 Xtest2 call setline(1, 'testtext 1 1') @@ -117,10 +117,6 @@ func Test_winbuf_close() call assert_equal('Xtest3', bufname('%')) call assert_fails('silent! quit!', 'E37:') call assert_equal('Xtest1', bufname('%')) - - call delete('Xtest1') - call delete('Xtest2') - call delete('Xtest3') endfunc " Test that ":close" will respect 'winfixheight' when possible. |