From: Kienan Stewart Date: Thu, 13 Feb 2025 14:14:15 +0000 (-0500) Subject: tests: Force consumerd_testpoint to always be verbose X-Git-Url: http://git.lttng.org./?a=commitdiff_plain;h=e995b146f3456dd51fd76288db6dae9efdbce592;p=lttng-tools.git tests: Force consumerd_testpoint to always be verbose The `lttng_opt_*` variables aren't actually shared with the consumerd. When running the consumerd with `--verbose`, the debug messages from this library were not visible. Using dlsym() to find the next `lttng_opt_verbose` does find a symbol, but despite the consumerd running with `--verbose`, the value of that symbol was 0. As these testpoints are only used in a couple of situations during the CI run, the local verbosity level can be forced high to always have the information available. Change-Id: Ife79be898f4534f16fc5ee587cb152bb1c591b31 Signed-off-by: Kienan Stewart Signed-off-by: Jérémie Galarneau --- diff --git a/tests/regression/tools/notification/consumer_testpoints.cpp b/tests/regression/tools/notification/consumer_testpoints.cpp index 834fff165..dedaba309 100644 --- a/tests/regression/tools/notification/consumer_testpoints.cpp +++ b/tests/regression/tools/notification/consumer_testpoints.cpp @@ -26,8 +26,6 @@ using lttng_consumer_get_type_func = enum lttng_consumer_type (*)(); static lttng_consumer_get_type_func lttng_consumer_get_type; int lttng_opt_verbose; -int lttng_opt_mi; -int lttng_opt_quiet; static void __attribute__((destructor)) pause_pipe_fini() { @@ -55,6 +53,12 @@ int __testpoint_consumerd_thread_data(void) int ret = 0; const char *pause_pipe_path_prefix, *domain; + /* + * lttng_opt_verbose does not refer to the same one as loaded in the consumerd. + * For the debug mode for this TU, as it's only used in testing. + */ + lttng_opt_verbose = 3; + pause_pipe_path_prefix = lttng_secure_getenv("CONSUMER_PAUSE_PIPE_PATH"); if (!pause_pipe_path_prefix) { ret = -1;