forked from aniani/vim
Problem: test_writefile and test_viml do not delete the tempfile. Solution: Delete the tempfile. (Charles Cooper) Add DeleteTheScript().
20 lines
373 B
Plaintext
20 lines
373 B
Plaintext
Tests for writefile()
|
|
|
|
STARTTEST
|
|
:source small.vim
|
|
:%delete _
|
|
:let f = tempname()
|
|
:call writefile(["over","written"], f, "b")
|
|
:call writefile(["hello","world"], f, "b")
|
|
:call writefile(["!", "good"], f, "a")
|
|
:call writefile(["morning"], f, "ab")
|
|
:call writefile(["", "vimmers"], f, "ab")
|
|
:bwipeout!
|
|
:$put =readfile(f)
|
|
:1 delete _
|
|
:w! test.out
|
|
:call delete(f)
|
|
:qa!
|
|
ENDTEST
|
|
|