1 #include <gtest/gtest.h> 70 const std::vector<double> joint_angles = { 0, 0.1, 0.2, 0.3, 0.4, 0.5 };
77 geometry_msgs::Pose fk_pose_msgs;
79 const std::vector<geometry_msgs::Pose> fk_poses = { fk_pose_msgs };
82 std::vector<std::vector<double> > solutions;
89 bool success = solver->getPositionIK(fk_poses, joint_angles, solutions, result, options);
92 std::size_t num_solutions = solutions.size();
93 ASSERT_GT(num_solutions, 0);
96 Eigen::Affine3d actual_pose;
97 for (
auto js : solutions)
105 int main(
int argc,
char** argv)
107 ros::init(argc, argv,
"moveit_opw_kinematics_test_fanuc");
108 testing::InitGoogleTest(&argc, argv);
109 return RUN_ALL_TESTS();
const std::string GROUP_PARAM
int main(int argc, char **argv)
robot_model::RobotModelPtr robot_model_
void poseEigenToMsg(const Eigen::Affine3d &e, geometry_msgs::Pose &m)
ROSCPP_DECL void init(int &argc, char **argv, const std::string &name, uint32_t options=0)
const std::string TIP_LINK_PARAM
TEST_F(TestKinematicsFanuc, InitOk)
void comparePoses(const Transform< T > &Ta, const Transform< T > &Tb)
Compare every element of two eigen affine3 poses.
robot_model::JointModelGroup * joint_model_group_
bool getParam(const std::string &key, std::string &s) const
const std::string ROBOT_DESCRIPTION
const robot_model::RobotModelPtr & getModel() const
const std::string ROOT_LINK_PARAM
#define ROS_ERROR_STREAM(args)
const double DEFAULT_SEARCH_DISCRETIZATION
robot_state::RobotStatePtr robot_state_