Skip to content

Commit

Permalink
Fix tests for RobotDynamicsEstimator library
Browse files Browse the repository at this point in the history
  • Loading branch information
isorrentino committed Feb 25, 2025
1 parent c15a683 commit cb496fd
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
#include <catch2/catch_test_macros.hpp>
#include <catch2/generators/catch_generators_all.hpp>

#include <iCubModels/iCubModels.h>
#include <yarp/os/ResourceFinder.h>
#include <ResolveRoboticsURICpp.h>

#include <iDynTree/KinDynComputations.h>
#include <iDynTree/FreeFloatingState.h>
Expand All @@ -34,7 +34,11 @@ void createModelLoader(IParametersHandler::shared_ptr group, iDynTree::ModelLoad
// List of joints and fts to load the model
std::vector<SubModel> subModelList;

const std::string modelPath = iCubModels::getModelFile("iCubGenova09");
std::optional<std::string> pathTemp = ResolveRoboticsURICpp::resolveRoboticsURI("package://ergoCub/robots/ergoCubSN000/model.urdf");
REQUIRE(pathTemp.has_value());

std::string modelPath = pathTemp.value();
BipedalLocomotion::log()->info("Model path {}", modelPath);

std::vector<std::string> jointList;
REQUIRE(group->getParameter("joint_list", jointList));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include <catch2/catch_test_macros.hpp>
#include <catch2/generators/catch_generators_all.hpp>

#include <iCubModels/iCubModels.h>
#include <ResolveRoboticsURICpp.h>
#include <yarp/os/ResourceFinder.h>

#include <iDynTree/KinDynComputations.h>
Expand All @@ -34,7 +34,11 @@ void createModelLoader(IParametersHandler::shared_ptr group, iDynTree::ModelLoad
// List of joints and fts to load the model
std::vector<SubModel> subModelList;

const std::string modelPath = iCubModels::getModelFile("iCubGenova09");
std::optional<std::string> pathTemp = ResolveRoboticsURICpp::resolveRoboticsURI("package://ergoCub/robots/ergoCubSN000/model.urdf");
REQUIRE(pathTemp.has_value());

std::string modelPath = pathTemp.value();
BipedalLocomotion::log()->info("Model path {}", modelPath);

std::vector<std::string> jointList;
REQUIRE(group->getParameter("joint_list", jointList));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#include <catch2/generators/catch_generators_all.hpp>
#include <chrono>

#include <iCubModels/iCubModels.h>
#include <ResolveRoboticsURICpp.h>
#include <yarp/os/ResourceFinder.h>

#include <iDynTree/KinDynComputations.h>
Expand All @@ -35,7 +35,11 @@ void createModelLoader(IParametersHandler::shared_ptr group, iDynTree::ModelLoad
// List of joints and fts to load the model
std::vector<SubModel> subModelList;

const std::string modelPath = iCubModels::getModelFile("iCubGenova09");
std::optional<std::string> pathTemp = ResolveRoboticsURICpp::resolveRoboticsURI("package://ergoCub/robots/ergoCubSN000/model.urdf");
REQUIRE(pathTemp.has_value());

std::string modelPath = pathTemp.value();
BipedalLocomotion::log()->info("Model path {}", modelPath);

std::vector<std::string> jointList;
REQUIRE(group->getParameter("joint_list", jointList));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include <catch2/catch_test_macros.hpp>
#include <catch2/generators/catch_generators_all.hpp>

#include <iCubModels/iCubModels.h>
#include <ResolveRoboticsURICpp.h>
#include <yarp/os/ResourceFinder.h>

#include <iDynTree/KinDynComputations.h>
Expand All @@ -35,7 +35,11 @@ void createModelLoader(IParametersHandler::shared_ptr group, iDynTree::ModelLoad
// List of joints and fts to load the model
std::vector<SubModel> subModelList;

const std::string modelPath = iCubModels::getModelFile("iCubGenova09");
std::optional<std::string> pathTemp = ResolveRoboticsURICpp::resolveRoboticsURI("package://ergoCub/robots/ergoCubSN000/model.urdf");
REQUIRE(pathTemp.has_value());

std::string modelPath = pathTemp.value();
BipedalLocomotion::log()->info("Model path {}", modelPath);

std::vector<std::string> jointList;
REQUIRE(group->getParameter("joint_list", jointList));
Expand Down

0 comments on commit cb496fd

Please sign in to comment.