Skip to content

Commit

Permalink
Fixes flaky RobotState test
Browse files Browse the repository at this point in the history
  • Loading branch information
TSNoble committed Nov 15, 2024
1 parent ce78cc4 commit 748efc7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions moveit_core/robot_state/test/robot_state_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -781,6 +781,8 @@ TEST_F(OneRobot, rigidlyConnectedParent)
EXPECT_EQ(robot_model_->getRigidlyConnectedParentLinkModel(link_b), link_a);

moveit::core::RobotState state(robot_model_);
state.setToDefaultValues();
state.updateLinkTransforms();

EXPECT_EQ(state.getRigidlyConnectedParentLinkModel("link_b"), link_a);

Expand All @@ -790,6 +792,9 @@ TEST_F(OneRobot, rigidlyConnectedParent)
EigenSTL::vector_Isometry3d{}, std::set<std::string>{}, trajectory_msgs::msg::JointTrajectory{},
moveit::core::FixedTransformsMap{ { "subframe", Eigen::Isometry3d::Identity() } }));

// This may be redundant
state.updateLinkTransforms();

// RobotState's version should resolve these too
EXPECT_EQ(link_a, state.getRigidlyConnectedParentLinkModel("object"));
EXPECT_EQ(link_a, state.getRigidlyConnectedParentLinkModel("object/subframe"));
Expand Down

0 comments on commit 748efc7

Please sign in to comment.