aboutsummaryrefslogtreecommitdiff
path: root/test/functional/helpers.lua
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/helpers.lua')
-rw-r--r--test/functional/helpers.lua7
1 files changed, 3 insertions, 4 deletions
diff --git a/test/functional/helpers.lua b/test/functional/helpers.lua
index 5eec5638f5..6e750b31a9 100644
--- a/test/functional/helpers.lua
+++ b/test/functional/helpers.lua
@@ -221,11 +221,10 @@ local function spawn(argv, merge)
return Session.new(child_stream)
end
-local function clear(extra_cmd)
+local function clear(...)
local args = {unpack(nvim_argv)}
- if extra_cmd ~= nil then
- table.insert(args, '--cmd')
- table.insert(args, extra_cmd)
+ for _, arg in ipairs({...}) do
+ table.insert(args, arg)
end
set_session(spawn(args))
end