diff options
Diffstat (limited to 'test/functional/helpers.lua')
-rw-r--r-- | test/functional/helpers.lua | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/test/functional/helpers.lua b/test/functional/helpers.lua index db2122565b..33d04616a0 100644 --- a/test/functional/helpers.lua +++ b/test/functional/helpers.lua @@ -217,10 +217,7 @@ end local function source(code) local tmpname = os.tmpname() - local tmpfile = io.open(tmpname, "w") - tmpfile:write(code) - tmpfile:flush() - tmpfile:close() + write_file(tmpname, code) nvim_command('source '..tmpname) os.remove(tmpname) end |