commit - 7b7d44f7459bc3df92143f6c4cac0bb415557a79
commit + ba249cc8f592e9e64a2e6eee6fdf19e7cb89f7db
blob - c77d78d7ba2036d8143a78ae6194e8968952fc64
blob + bee19624f75fba5f5ea998fda73c940a4beef6fd
--- test/app-luatest/gh_8083_fatal_signal_handler_test.lua
+++ test/app-luatest/gh_8083_fatal_signal_handler_test.lua
+local fio = require('fio')
local t = require('luatest')
local g = t.group('gh-8083', {{errinj = 'ERRINJ_SIGILL_MAIN_THREAD'},
{errinj = 'ERRINJ_SIGILL_NONMAIN_THREAD'}})
g.before_each(function(cg)
- local server = require('luatest.server')
- cg.server = server:new({alias = 'master'})
+ cg.tempdir = fio.tempdir()
end)
g.after_each(function(cg)
- cg.server:drop()
+ fio.rmtree(cg.tempdir)
end)
-- Check that forked Tarantool creates a crash report on the illegal instruction
-- Use `cd' and `shell = true' due to lack of cwd option in popen (gh-5633),
-- `feedback_enabled = false' to avoid forking for sending feedback.
local fmt = 'cd %s && %s -e "box.cfg{feedback_enabled = false} os.exit()"'
- local cmd = string.format(fmt, cg.server.workdir, tarantool_exe)
+ local cmd = string.format(fmt, cg.tempdir, tarantool_exe)
local ph = popen.new({cmd}, {stderr = popen.opts.PIPE, env = tarantool_env,
shell = true})
t.assert(ph)
blob - d2af12d04e4672cde97b8bfb0497d414306e44d9
blob + 4b76ce5bfbcb12d47fd4874ba390e587824cde26
--- test/app-luatest/gh_8445_crash_during_crash_report_test.lua
+++ test/app-luatest/gh_8445_crash_during_crash_report_test.lua
+local fio = require('fio')
local t = require('luatest')
local g = t.group('gh-8445')
-g.before_all(function(cg)
- local server = require('luatest.server')
- cg.server = server:new({alias = 'gh-8445'})
+g.before_each(function(cg)
+ cg.tempdir = fio.tempdir()
end)
-g.after_all(function(cg)
- cg.server:drop()
+g.after_each(function(cg)
+ fio.rmtree(cg.tempdir)
end)
-- Check that forked Tarantool doesn't crash when preparing a crash report.
-- Use `cd' and `shell = true' due to lack of cwd option in popen (gh-5633).
local exe = arg[-1]
- local dir = cg.server.workdir
+ local dir = cg.tempdir
local cmd = [[
cd %s && %s -e "box.cfg{} require('log').info('pid = ' .. box.info.pid)"
]]
blob - 345fc57b855a3630e225d0ac607dadac874e2bd0
blob + aac59814f05e074c02d06b9f4cda5651bcdb7088
--- test/box-luatest/gh_7434_yield_in_on_shutdown_trigger_test.lua
+++ test/box-luatest/gh_7434_yield_in_on_shutdown_trigger_test.lua
local output_file
g.before_all(function(cg)
- local server = require('luatest.server')
- cg.server = server:new({alias = 'master'})
- output_file = cg.server.workdir .. '/on_shutdown_completed.txt'
+ cg.tempdir = fio.tempdir()
+ output_file = cg.tempdir .. '/on_shutdown_completed.txt'
end)
g.after_each(function()
os.remove(output_file)
end)
+g.after_all(function(cg)
+ fio.rmtree(cg.tempdir)
+end)
+
-- Shutdown by reaching the end of the script
g.test_finish = function()
local ph = popen.new({tarantool, script, output_file})