patch 9.0.0418: manually deleting temp test files
Problem: Manually deleting temp test files.
Solution: Use the 'D' flag of writefile() and mkdir().
diff --git a/src/testdir/test_conceal.vim b/src/testdir/test_conceal.vim
index 24fe69b..c0a46dc 100644
--- a/src/testdir/test_conceal.vim
+++ b/src/testdir/test_conceal.vim
@@ -25,7 +25,7 @@
exe "normal /here\r"
[CODE]
- call writefile(code, 'XTest_conceal')
+ call writefile(code, 'XTest_conceal', 'D')
" Check that cursor line is concealed
let buf = RunVimInTerminal('-S XTest_conceal', {})
call VerifyScreenDump(buf, 'Test_conceal_two_windows_01', {})
@@ -109,7 +109,6 @@
" clean up
call StopVimInTerminal(buf)
- call delete('XTest_conceal')
endfunc
func Test_conceal_with_cursorline()
@@ -126,7 +125,7 @@
normal M
[CODE]
- call writefile(code, 'XTest_conceal_cul')
+ call writefile(code, 'XTest_conceal_cul', 'D')
let buf = RunVimInTerminal('-S XTest_conceal_cul', {})
call VerifyScreenDump(buf, 'Test_conceal_cul_01', {})
@@ -138,7 +137,6 @@
" clean up
call StopVimInTerminal(buf)
- call delete('XTest_conceal_cul')
endfunc
func Test_conceal_resize_term()
@@ -150,7 +148,7 @@
syn region CommentCodeSpan matchgroup=Comment start=/`/ end=/`/ concealends
normal fb
[CODE]
- call writefile(code, 'XTest_conceal_resize')
+ call writefile(code, 'XTest_conceal_resize', 'D')
let buf = RunVimInTerminal('-S XTest_conceal_resize', {'rows': 6})
call VerifyScreenDump(buf, 'Test_conceal_resize_01', {})
@@ -159,7 +157,6 @@
" clean up
call StopVimInTerminal(buf)
- call delete('XTest_conceal_resize')
endfunc
" Tests for correct display (cursor column position) with +conceal and
@@ -247,7 +244,7 @@
:q!
[CODE]
- call writefile(code, 'XTest_conceal_curpos')
+ call writefile(code, 'XTest_conceal_curpos', 'D')
if RunVim([], [], '-s XTest_conceal_curpos')
call assert_equal([
@@ -258,7 +255,6 @@
endif
call delete('Xconceal_curpos.out')
- call delete('XTest_conceal_curpos')
endfunc
func Test_conceal_eol()