diff options
Diffstat (limited to 'test/functional/helpers.lua')
-rw-r--r-- | test/functional/helpers.lua | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/test/functional/helpers.lua b/test/functional/helpers.lua index 7cb562a776..7851a0fcba 100644 --- a/test/functional/helpers.lua +++ b/test/functional/helpers.lua @@ -394,17 +394,16 @@ end -- removed, e.g. args_rm={'--cmd'} removes all cases of "--cmd" -- (and its value) from the default set. -- env: Map: Defines the environment of the new session. --- headless: Boolean (default=true): Append --headless arg. -- -- Example: -- clear('-e') -- clear{args={'-e'}, args_rm={'-i'}, env={TERM=term}} local function clear(...) local args = {unpack(nvim_argv)} + table.insert(args, '--headless') local new_args local env = nil local opts = select(1, ...) - local headless = true if type(opts) == 'table' then args = remove_args(args, opts.args_rm) if opts.env then @@ -432,15 +431,9 @@ local function clear(...) end end new_args = opts.args or {} - if opts.headless == false then - headless = false - end else new_args = {...} end - if headless then - table.insert(args, '--headless') - end for _, arg in ipairs(new_args) do table.insert(args, arg) end |