From c4dbfc9d2f1ac0d7eccfa85b6d939eb69f9cf7eb Mon Sep 17 00:00:00 2001 From: Christoph Froehlich Date: Tue, 17 Dec 2024 20:32:38 +0000 Subject: [PATCH] Increase margin for publish rate --- .../test/test_trajectory_controller.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/joint_trajectory_controller/test/test_trajectory_controller.cpp b/joint_trajectory_controller/test/test_trajectory_controller.cpp index 003480e9c9..dd977c4c43 100644 --- a/joint_trajectory_controller/test/test_trajectory_controller.cpp +++ b/joint_trajectory_controller/test/test_trajectory_controller.cpp @@ -880,7 +880,7 @@ void TrajectoryControllerTest::test_state_publish_rate_target(int target_msg_cou } // We may miss the last message since time allowed is exactly the time needed - EXPECT_NEAR(target_msg_count, echo_received_counter, 1); + EXPECT_NEAR(target_msg_count, echo_received_counter, 2); executor.cancel(); } @@ -893,10 +893,10 @@ TEST_P(TrajectoryControllerTestParameterized, test_state_publish_rate) test_state_publish_rate_target(10); } -// TEST_P(TrajectoryControllerTestParameterized, zero_state_publish_rate) -// { -// test_state_publish_rate_target(0); -// } +TEST_P(TrajectoryControllerTestParameterized, test_lower_state_publish_rate) +{ + test_state_publish_rate_target(1); +} /** * @brief check if use_closed_loop_pid is active