diff --git a/moveit_ros/planning/planning_scene_monitor/test/planning_scene_monitor_test.cpp b/moveit_ros/planning/planning_scene_monitor/test/planning_scene_monitor_test.cpp index 806a88f3ac..0547216437 100644 --- a/moveit_ros/planning/planning_scene_monitor/test/planning_scene_monitor_test.cpp +++ b/moveit_ros/planning/planning_scene_monitor/test/planning_scene_monitor_test.cpp @@ -59,6 +59,9 @@ class PlanningSceneMonitorTest : public ::testing::Test scene_ = planning_scene_monitor_->getPlanningScene(); executor_->add_node(test_node_); executor_thread_ = std::thread([this]() { executor_->spin(); }); + + // Needed to avoid race conditions on high-load CPUs. + std::this_thread::sleep_for(std::chrono::seconds{ 1 }); } void TearDown() override