Skip to content

Commit 66300f1

Browse files
add positive longitudinal velocity condition for straight_trajectory test
Signed-off-by: kyoichi-sugahara <kyoichi.sugahara@tier4.jp>
1 parent 33abcfa commit 66300f1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

control/trajectory_follower_node/test/test_controller_node.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -252,8 +252,10 @@ TEST_F(FakeNodeFixture, straight_trajectory)
252252

253253
test_utils::waitForMessage(tester.node, this, tester.received_control_command);
254254
ASSERT_TRUE(tester.received_control_command);
255+
// following conditions will pass even if the MPC solution does not converge
255256
EXPECT_EQ(tester.cmd_msg->lateral.steering_tire_angle, 0.0f);
256257
EXPECT_EQ(tester.cmd_msg->lateral.steering_tire_rotation_rate, 0.0f);
258+
EXPECT_GT(tester.cmd_msg->longitudinal.speed, 0.0f);
257259
EXPECT_GT(rclcpp::Time(tester.cmd_msg->stamp), rclcpp::Time(traj_msg.header.stamp));
258260
}
259261

0 commit comments

Comments
 (0)