@@ -258,6 +258,7 @@ class ActionTest : public ::testing::Test
258
258
259
259
TEST_F (ActionTest, test_simple_action)
260
260
{
261
+ std::this_thread::sleep_for (std::chrono::milliseconds (1000 ));
261
262
node_->activate_server ();
262
263
263
264
// The goal for this invocation
@@ -272,6 +273,7 @@ TEST_F(ActionTest, test_simple_action)
272
273
future_goal_handle), rclcpp::FutureReturnCode::SUCCESS);
273
274
274
275
auto goal_handle = future_goal_handle.get ();
276
+ EXPECT_NE (goal_handle, nullptr );
275
277
276
278
// Wait for the result
277
279
auto future_result = node_->action_client_ ->async_get_result (goal_handle);
@@ -320,6 +322,7 @@ TEST_F(ActionTest, test_simple_action_with_feedback)
320
322
future_goal_handle), rclcpp::FutureReturnCode::SUCCESS);
321
323
322
324
auto goal_handle = future_goal_handle.get ();
325
+ EXPECT_NE (goal_handle, nullptr );
323
326
324
327
// Wait for the result
325
328
auto future_result = node_->action_client_ ->async_get_result (goal_handle);
@@ -364,6 +367,7 @@ TEST_F(ActionTest, test_simple_action_activation_cycling)
364
367
node_->deactivate_server ();
365
368
366
369
auto goal_handle = future_goal_handle.get ();
370
+ EXPECT_NE (goal_handle, nullptr );
367
371
368
372
// Wait for the result
369
373
auto future_result = node_->action_client_ ->async_get_result (goal_handle);
@@ -430,6 +434,7 @@ TEST_F(ActionTest, test_simple_action_preemption)
430
434
future_goal_handle), rclcpp::FutureReturnCode::SUCCESS);
431
435
432
436
auto goal_handle = future_goal_handle.get ();
437
+ EXPECT_NE (goal_handle, nullptr );
433
438
434
439
// Wait for the result
435
440
auto future_result = node_->action_client_ ->async_get_result (goal_handle);
@@ -478,6 +483,7 @@ TEST_F(ActionTest, test_simple_action_preemption_after_succeeded)
478
483
479
484
// Get the results
480
485
auto goal_handle = future_goal_handle.get ();
486
+ EXPECT_NE (goal_handle, nullptr );
481
487
482
488
// Wait for the result of initial goal
483
489
auto future_result = node_->action_client_ ->async_get_result (goal_handle);
0 commit comments