diff options
author | Bram Moolenaar <Bram@vim.org> | 2016-01-17 18:34:19 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2016-01-17 18:34:19 +0100 |
commit | 08b270a8a4544be9a7fecce311834fde2b457634 (patch) | |
tree | 4a46e9dc5cbdf0773afd59b721e5543fc35e67ff /src/testdir/test_expand.vim | |
parent | 336bd622c31e1805495c034e1a8cfadcc0bbabc7 (diff) | |
download | vim-git-08b270a8a4544be9a7fecce311834fde2b457634.tar.gz |
patch 7.4.1121v7.4.1121
Problem: test_expand leaves files behind.
Solution: Edit another file before deleting, otherwise the swap file
remains.
Diffstat (limited to 'src/testdir/test_expand.vim')
-rw-r--r-- | src/testdir/test_expand.vim | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/testdir/test_expand.vim b/src/testdir/test_expand.vim index a68c4226f..c099edae1 100644 --- a/src/testdir/test_expand.vim +++ b/src/testdir/test_expand.vim @@ -20,10 +20,13 @@ func Test_with_directories() next! Xdir?/*/nofile call assert_equal('Xdir?/*/nofile', expand('%')) endif + " Edit another file, on MS-Windows the swap file would be in use and can't + " be deleted. + edit foo - call delete('Xdir1', 'rf') - call delete('Xdir2', 'rf') - call delete('Xdir3', 'rf') + call assert_equal(0, delete('Xdir1', 'rf')) + call assert_equal(0, delete('Xdir2', 'rf')) + call assert_equal(0, delete('Xdir3', 'rf')) endfunc func Test_with_tilde() |