1
0
forked from aniani/vim

patch 9.0.0625: too many delete() calls in tests

Problem:    Too many delete() calls in tests.
Solution:   Use deferred delete where possible.
This commit is contained in:
Bram Moolenaar
2022-09-29 21:01:57 +01:00
parent ac38ec7c7f
commit 7dd5a78b88
10 changed files with 47 additions and 80 deletions

View File

@@ -161,7 +161,7 @@ func Test_modeline_indent_expr()
func GetIndent()
return line('.') * 2
endfunc
call writefile(['# vim: indentexpr=GetIndent()'], 'Xmlfile.txt')
call writefile(['# vim: indentexpr=GetIndent()'], 'Xmlfile.txt', 'D')
set modelineexpr
new Xmlfile.txt
call assert_equal('GetIndent()', &indentexpr)
@@ -172,7 +172,6 @@ func Test_modeline_indent_expr()
delfunc GetIndent
let &modeline = modeline
close!
call delete('Xmlfile.txt')
endfunc
func Test_indent_func_with_gq()