Skip to content

Commit

Permalink
tests: zbus: publish_stats: Fix for non-zero boot delay
Browse files Browse the repository at this point in the history
Fixes the zbus publishing statistics test to account for a non-zero boot
delay, which is often used in hardware testing environments. This fixes
an assertion failure observed on multiple max32 boards in the adi board
farm.

Signed-off-by: Maureen Helm <[email protected]>
  • Loading branch information
MaureenHelm authored and dkalowsk committed Nov 6, 2024
1 parent 5106a04 commit 130c5c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/subsys/zbus/publish_stats/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ ZTEST(publish_stats, test_channel_metadata)
zassert_equal(0, zbus_chan_pub_stats_avg_period(&chan));

/* Should be no different after a second of runtime */
k_sleep(K_SECONDS(1));
k_sleep(K_TIMEOUT_ABS_MS(1000));
zassert_equal(0, zbus_chan_pub_stats_count(&chan));
zassert_equal(0, zbus_chan_pub_stats_last_time(&chan));
zassert_equal(0, zbus_chan_pub_stats_avg_period(&chan));
Expand Down

0 comments on commit 130c5c0

Please sign in to comment.