From: Kienan Stewart Date: Mon, 12 Aug 2024 19:59:15 +0000 (-0400) Subject: Tests: Add and set new log-file-d for the tap driver X-Git-Url: http://git.lttng.org./?a=commitdiff_plain;h=aa5439fbe18d07c8a19a4fc344847c453f52981c;p=lttng-tools.git Tests: Add and set new log-file-d for the tap driver This adds a new option `--log-file-d` to the tap-driver, which will create a `*.log.d` folder for each test when running `make check` and the `LTTNG_TEST_LOG_DIR` accordingly. Doing so allows the tests to be run in verbose and create logs in a predictable location. These log folders are removed when running `make clean`. Change-Id: Ibcf7e2cb54098a3e9ccd828ca76df6efcf33431d Signed-off-by: Kienan Stewart Signed-off-by: Jérémie Galarneau --- diff --git a/tests/regression/Makefile.am b/tests/regression/Makefile.am index 5a8eebd9b..6537a33dd 100644 --- a/tests/regression/Makefile.am +++ b/tests/regression/Makefile.am @@ -148,3 +148,8 @@ endif if PRECIOUS_TESTS .PRECIOUS: $(TEST_LOGS) endif + +mostlyclean-local: + @for f in $(TESTS); do \ + rm -rf "$$f.log.d/"; \ + done diff --git a/tests/utils/tap-driver.sh b/tests/utils/tap-driver.sh index 56d4d3e45..e2d9ad9c6 100755 --- a/tests/utils/tap-driver.sh +++ b/tests/utils/tap-driver.sh @@ -49,6 +49,7 @@ print_usage () cat <