Skip to content

Commit f2a8baf

Browse files
committed
patch 8.2.3440: recover test fails if there is an old swap file
Problem: Recover test fails if there is an old swap file. Solution: Delete old swap files.
1 parent 78eb9cc commit f2a8baf

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

src/testdir/test_recover.vim

+6
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,12 @@ func Test_recover_empty_swap_file()
170170
call assert_match('Unable to read block 0 from .Xfile1.swp', msg)
171171
call assert_equal('Xfile1', @%)
172172
bw!
173+
174+
" make sure there are no old swap files laying around
175+
for f in glob('.sw?', 0, 1)
176+
call delete(f)
177+
endfor
178+
173179
" :recover from an empty buffer
174180
call assert_fails('recover', 'E305:')
175181
call delete('.Xfile1.swp')

src/version.c

+2
Original file line numberDiff line numberDiff line change
@@ -755,6 +755,8 @@ static char *(features[]) =
755755

756756
static int included_patches[] =
757757
{ /* Add new patch number below this line */
758+
/**/
759+
3440,
758760
/**/
759761
3439,
760762
/**/

0 commit comments

Comments
 (0)