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 Jul 25, 2024
1 parent e4b7827 commit d8f78a2
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 @@ -89,9 +89,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 @@ -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 @@ -73,9 +73,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 @@ -77,9 +77,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 @@ -97,9 +97,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 @@ -84,9 +84,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 @@ -70,9 +70,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 @@ -81,9 +81,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 @@ -84,9 +84,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 d8f78a2

Please sign in to comment.