Skip to content

Commit

Permalink
adapt test to new way of exporting reference interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
mamueluth committed May 22, 2024
1 parent 4008030 commit aa336fc
Show file tree
Hide file tree
Showing 9 changed files with 27 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,9 @@ TEST_F(AckermannSteeringControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + joint_reference_interfaces_[i];
EXPECT_EQ(reference_interfaces[i].get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i].get_interface_name(), joint_reference_interfaces_[i]);
EXPECT_EQ(reference_interfaces[i]->get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i]->get_interface_name(), joint_reference_interfaces_[i]);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,9 @@ TEST_F(AckermannSteeringControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + joint_reference_interfaces_[i];
EXPECT_EQ(reference_interfaces[i].get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i].get_interface_name(), joint_reference_interfaces_[i]);
EXPECT_EQ(reference_interfaces[i]->get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i]->get_interface_name(), joint_reference_interfaces_[i]);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,9 @@ TEST_F(BicycleSteeringControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + joint_reference_interfaces_[i];
EXPECT_EQ(reference_interfaces[i].get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i].get_interface_name(), joint_reference_interfaces_[i]);
EXPECT_EQ(reference_interfaces[i]->get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i]->get_interface_name(), joint_reference_interfaces_[i]);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,9 @@ TEST_F(BicycleSteeringControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + joint_reference_interfaces_[i];
EXPECT_EQ(reference_interfaces[i].get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i].get_interface_name(), joint_reference_interfaces_[i]);
EXPECT_EQ(reference_interfaces[i]->get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i]->get_interface_name(), joint_reference_interfaces_[i]);
}
}

Expand Down
6 changes: 3 additions & 3 deletions pid_controller/test/test_pid_controller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,9 @@ TEST_F(PidControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + dof_name + "/" + interface;
EXPECT_EQ(ref_if_conf[ri_index].get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[ri_index].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[ri_index].get_interface_name(), dof_name + "/" + interface);
EXPECT_EQ(ref_if_conf[ri_index]->get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[ri_index]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[ri_index]->get_interface_name(), dof_name + "/" + interface);
++ri_index;
}
}
Expand Down
6 changes: 3 additions & 3 deletions pid_controller/test/test_pid_controller_preceding.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,9 @@ TEST_F(PidControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + dof_name + "/" + interface;
EXPECT_EQ(ref_if_conf[ri_index].get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[ri_index].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[ri_index].get_interface_name(), dof_name + "/" + interface);
EXPECT_EQ(ref_if_conf[ri_index]->get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[ri_index]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[ri_index]->get_interface_name(), dof_name + "/" + interface);
++ri_index;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,9 @@ TEST_F(SteeringControllersLibraryTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + joint_reference_interfaces_[i];
EXPECT_EQ(reference_interfaces[i].get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i].get_interface_name(), joint_reference_interfaces_[i]);
EXPECT_EQ(reference_interfaces[i]->get_name(), ref_itf_name);
EXPECT_EQ(reference_interfaces[i]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(reference_interfaces[i]->get_interface_name(), joint_reference_interfaces_[i]);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,9 @@ TEST_F(TricycleSteeringControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + joint_reference_interfaces_[i];
EXPECT_EQ(ref_if_conf[i].get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[i].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[i].get_interface_name(), joint_reference_interfaces_[i]);
EXPECT_EQ(ref_if_conf[i]->get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[i]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[i]->get_interface_name(), joint_reference_interfaces_[i]);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,9 @@ TEST_F(TricycleSteeringControllerTest, check_exported_interfaces)
{
const std::string ref_itf_name =
std::string(controller_->get_node()->get_name()) + "/" + joint_reference_interfaces_[i];
EXPECT_EQ(ref_if_conf[i].get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[i].get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[i].get_interface_name(), joint_reference_interfaces_[i]);
EXPECT_EQ(ref_if_conf[i]->get_name(), ref_itf_name);
EXPECT_EQ(ref_if_conf[i]->get_prefix_name(), controller_->get_node()->get_name());
EXPECT_EQ(ref_if_conf[i]->get_interface_name(), joint_reference_interfaces_[i]);
}
}

Expand Down

0 comments on commit aa336fc

Please sign in to comment.