This repository has been archived by the owner on Jun 10, 2021. It is now read-only.
LinuxMemoryMeasurementTestFixture.TestPublishMetricsMessage test is flaky #96
Labels
bug
Something isn't working
Description
LinuxMemoryMeasurementTestFixture.TestPublishMetricsMessage is flaky
Expected Behavior
The test should always succeed.
Actual Behavior
The test sometimes fail because it relies on having messages processed "fast enough". This has been reported in an ASAN build, most likely due to the fact that ASAN builds are slower than normal builds.
https://github.com/ros-tooling/system_metrics_collector/runs/470335108?check_suite_focus=true
Failed test output
To Reproduce
Run:
Wait until it starts failing. On fast workstations, buildling with ASAN enabled may be necessary to slow-down the execution enough to exhibit the bug.
System (please complete the following information)
master
Additional context
To make this bug reliable, each step in the test needs to wait until the ROS messages are actually processed. The callback may switch a
std::atomic_bool
or astd::atomic_flag
for instance. Blocking until the lifecycle API starts reporting the new state may also be another possibility.If waiting for messages to be processed is not enough, we should explore whether cache coherency could play a role in this bug.
The text was updated successfully, but these errors were encountered: