From ddee8b78d4e12d9e4903b859b28723bf6470680c Mon Sep 17 00:00:00 2001 From: Vladimir Davydov Date: Wed, 28 Aug 2024 15:59:44 +0300 Subject: [PATCH] Create luatest.log file in VARDIR Currently, it's created in the current directory, which is annoying. Fixes commit f8a1c10baa482 ("Add logging to unified file"). Closes #373 --- luatest/runner.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/luatest/runner.lua b/luatest/runner.lua index b164726..05a680d 100644 --- a/luatest/runner.lua +++ b/luatest/runner.lua @@ -61,6 +61,9 @@ function Runner.run(args, options) local log_prefix = options.log_prefix or 'luatest' local log_cfg = string.format("%s.log", log_prefix) + fio.mktree(Server.vardir) + log_cfg = fio.pathjoin(Server.vardir, log_cfg) + if options.log_file then -- Save the file descriptor as a global variable to use it -- in the `output_beautifier` module: this module is connected to the