[PATCH 07/11] tests: dump log contents on assert_log_contains failure
Wander Lairson Costa <[email protected]> Fri, 10 Jul 2026 10:38:06 -0300
| Newsgroups | org.kernel.vger.linux-rt-users |
|---|---|
| Message-ID | <[email protected]> |
assert_starvation_detected and assert_boost_detected already dump the log file before calling fail, but assert_log_contains does not, making failures harder to diagnose in CI. Add the same log-dump pattern so the file contents appear in the output on any assertion failure. Signed-off-by: Wander Lairson Costa <[email protected]> --- tests/helpers/test_helpers.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/helpers/test_helpers.sh b/tests/helpers/test_helpers.sh index 20937a3..a2db0a9 100755 --- a/tests/helpers/test_helpers.sh +++ b/tests/helpers/test_helpers.sh @@ -209,6 +209,8 @@ assert_log_contains() { else log " Pattern '${pattern}' not found in ${log_file}" fi + log "Log contents:" + cat "${log_file}" fail "${message}" fi } -- 2.55.0