Skip to content
Snippets Groups Projects
Commit 130335e4 authored by Alexander Turenko's avatar Alexander Turenko Committed by Alexander Turenko
Browse files

test: accept env in interactive_tarantool.new()

It is needed to fix a problem in the
`config-luatest/credentials_applier` test. See the next commit.

NO_DOC=It is a testing helper improvement.
NO_CHANGELOG=see NO_DOC
NO_TEST=see NO_DOC
parent 4b8bbe87
No related branches found
No related tags found
No related merge requests found
......@@ -294,6 +294,7 @@ end
function M._new_internal(opts)
local opts = opts or {}
local args = opts.args or {}
local env = opts.env or {}
local prompt = opts.prompt
local tarantool_exe = arg[-1]
......@@ -301,7 +302,7 @@ function M._new_internal(opts)
stdin = popen.opts.PIPE,
stdout = popen.opts.PIPE,
stderr = popen.opts.PIPE,
env = {
env = fun.chain({
-- Don't know why, but without defined TERM environment
-- variable readline doesn't accept INPUTRC environment
-- variable.
......@@ -313,7 +314,7 @@ function M._new_internal(opts)
-- (because the command in the echo output will be
-- trimmed).
INPUTRC = '/dev/null',
},
}, env):tomap(),
})
local res = setmetatable({
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment