From 2a6cb5f04a3432505884255ba95369548f517fc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Stasiak?= Date: Fri, 29 Aug 2025 15:15:34 +0200 Subject: [PATCH] [nrf fromlist] tests: drivers: timer: nrf_grtc_timer: wait for coverage dump MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If test is to be run in coverage mode, wait for output to dump at the end of a failing testcase. Upstream PR #: 95162 Signed-off-by: MichaƂ Stasiak --- tests/drivers/timer/nrf_grtc_timer/src/main.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/drivers/timer/nrf_grtc_timer/src/main.c b/tests/drivers/timer/nrf_grtc_timer/src/main.c index 9de554256b41..7e2b440a9aa1 100644 --- a/tests/drivers/timer/nrf_grtc_timer/src/main.c +++ b/tests/drivers/timer/nrf_grtc_timer/src/main.c @@ -393,6 +393,13 @@ static void grtc_stress_test(bool busy_sim_en) if (counter_dev) { counter_stop(counter_dev); } + +#ifdef CONFIG_COVERAGE + /* Wait a few seconds before exit, giving the test the + * opportunity to dump some output before coverage data gets emitted + */ + k_sleep(K_MSEC(5000)); +#endif } ZTEST(nrf_grtc_timer, test_stress)