Skip to content

Commit 0588ad0

Browse files
committed
Fix test
Signed-off-by: Alberto Tudela <[email protected]>
1 parent 0082e1a commit 0588ad0

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

test/test_integration.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,6 @@ TEST(LaserSegmentationTest, integration) {
5858
scan.ranges.push_back(3.0);
5959
scan.ranges.push_back(3.2);
6060
scan.ranges.push_back(12.0);
61-
// Publish the message
62-
scan_pub->publish(scan);
6361

6462
// Create the segments subscriber node
6563
auto sub_node = std::make_shared<rclcpp_lifecycle::LifecycleNode>("segment_subscriber");
@@ -74,6 +72,9 @@ TEST(LaserSegmentationTest, integration) {
7472
});
7573
auto sub_thread = std::thread([&]() {rclcpp::spin(sub_node->get_node_base_interface());});
7674

75+
// Publish the message
76+
scan_pub->publish(scan);
77+
7778
// Spin the laser_segmentation node
7879
rclcpp::spin_some(seg_node->get_node_base_interface());
7980

0 commit comments

Comments
 (0)