From 43d652c465f41008b9026e4aae560bced3a51f73 Mon Sep 17 00:00:00 2001 From: Remi Siffert Date: Mon, 18 Nov 2024 15:50:10 -0500 Subject: [PATCH] Fixed unit tests --- tests/test_rtde_client.cpp | 8 +++++--- tests/test_ur_driver.cpp | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/test_rtde_client.cpp b/tests/test_rtde_client.cpp index f92de29c..46b17161 100644 --- a/tests/test_rtde_client.cpp +++ b/tests/test_rtde_client.cpp @@ -142,11 +142,13 @@ TEST_F(RTDEClientTest, empty_recipe_file) TEST_F(RTDEClientTest, invalid_target_frequency) { // Setting target frequency below 0 or above 500, should throw an exception - client_.reset(new rtde_interface::RTDEClient(ROBOT_IP, notifier_, output_recipe_file_, input_recipe_file_, -1.0)); + client_.reset( + new rtde_interface::RTDEClient(ROBOT_IP, notifier_, output_recipe_file_, input_recipe_file_, false, -1.0)); EXPECT_THROW(client_->init(), UrException); - client_.reset(new rtde_interface::RTDEClient(ROBOT_IP, notifier_, output_recipe_file_, input_recipe_file_, 1000)); + client_.reset( + new rtde_interface::RTDEClient(ROBOT_IP, notifier_, output_recipe_file_, input_recipe_file_, false, 1000)); EXPECT_THROW(client_->init(), UrException); } @@ -165,7 +167,7 @@ TEST_F(RTDEClientTest, unconfigured_target_frequency) TEST_F(RTDEClientTest, set_target_frequency) { - client_.reset(new rtde_interface::RTDEClient(ROBOT_IP, notifier_, output_recipe_file_, input_recipe_file_, 1)); + client_.reset(new rtde_interface::RTDEClient(ROBOT_IP, notifier_, output_recipe_file_, input_recipe_file_, false, 1)); client_->init(); // Maximum frequency should still be equal to the robot's maximum frequency diff --git a/tests/test_ur_driver.cpp b/tests/test_ur_driver.cpp index 3bfcacc0..713babf5 100644 --- a/tests/test_ur_driver.cpp +++ b/tests/test_ur_driver.cpp @@ -375,7 +375,7 @@ TEST_F(UrDriverTest, send_robot_program_retry_on_failure) TEST_F(UrDriverTest, reset_rtde_client) { double target_frequency = 50; - g_ur_driver_->resetRTDEClient(OUTPUT_RECIPE, INPUT_RECIPE, target_frequency); + g_ur_driver_->resetRTDEClient(OUTPUT_RECIPE, INPUT_RECIPE, false, target_frequency); ASSERT_EQ(g_ur_driver_->getControlFrequency(), target_frequency); }