patch 9.0.0391: using separate delete() call instead of writefile() 'D' flag
Problem: Using separate delete() call instead of writefile() 'D' flag.
Solution: Use the writefile 'D' flag.
diff --git a/src/testdir/test_bufline.vim b/src/testdir/test_bufline.vim
index caf6aa7..f3502a3 100644
--- a/src/testdir/test_bufline.vim
+++ b/src/testdir/test_bufline.vim
@@ -81,11 +81,10 @@
if cmd == ''
return
endif
- call writefile(['call setline(1, "Hello")', 'silent w Xtest', 'q!'], 'Xscript')
+ call writefile(['call setline(1, "Hello")', 'silent w Xtest', 'q!'], 'Xscript', 'D')
call system(cmd)
call assert_equal(['Hello'], readfile('Xtest'))
- call delete('Xscript')
call delete('Xtest')
endfunc
@@ -214,12 +213,11 @@
call deletebufline(buf, 1, '$')
call appendbufline(buf, '$', 'Hello Vim world...')
END
- call writefile(lines, 'XscriptMatchCommon')
+ call writefile(lines, 'XscriptMatchCommon', 'D')
let buf = RunVimInTerminal('-S XscriptMatchCommon', #{rows: 10})
call VerifyScreenDump(buf, 'Test_appendbufline_1', {})
call StopVimInTerminal(buf)
- call delete('XscriptMatchCommon')
endfunc
func Test_setbufline_select_mode()