From 49d6415e7b798d5bad356c726203b737974b9504 Mon Sep 17 00:00:00 2001 From: AndyZe Date: Thu, 8 Dec 2022 15:28:00 -0600 Subject: [PATCH] Update the custom limits test --- .../test/test_time_optimal_trajectory_generation.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/moveit_core/trajectory_processing/test/test_time_optimal_trajectory_generation.cpp b/moveit_core/trajectory_processing/test/test_time_optimal_trajectory_generation.cpp index 5730f955ea..6b9a018e0d 100644 --- a/moveit_core/trajectory_processing/test/test_time_optimal_trajectory_generation.cpp +++ b/moveit_core/trajectory_processing/test/test_time_optimal_trajectory_generation.cpp @@ -174,8 +174,14 @@ TEST(time_optimal_trajectory_generation, test_custom_limits) TimeOptimalTrajectoryGeneration totg; // Custom velocity & acceleration limits for some joints - std::unordered_map vel_limits{ { "panda_joint1", 1.3 } }; - std::unordered_map accel_limits{ { "panda_joint2", 2.3 }, { "panda_joint3", 3.3 } }; + std::unordered_map vel_limits{ { "panda_joint1", 1.3 }, { "panda_joint2", 2.3 }, + { "panda_joint3", 3.3 }, { "panda_joint4", 4.3 }, + { "panda_joint5", 5.3 }, { "panda_joint6", 6.3 }, + { "panda_joint7", 7.3 } }; + std::unordered_map accel_limits{ { "panda_joint1", 1.3 }, { "panda_joint2", 2.3 }, + { "panda_joint3", 3.3 }, { "panda_joint4", 4.3 }, + { "panda_joint5", 5.3 }, { "panda_joint6", 6.3 }, + { "panda_joint7", 7.3 } }; ASSERT_TRUE(totg.computeTimeStamps(trajectory, vel_limits, accel_limits)) << "Failed to compute time stamps"; } @@ -256,7 +262,7 @@ TEST(time_optimal_trajectory_generation, testLargeAccel) } } -// TODO(andyz): commented because loadTestingRobotModel() does not parse acceleration limits +// TODO(andyz): commented because loadTestingRobotModel() does not parse acceleration limits from URDF // // Test parameterizing a trajectory would always produce a trajectory with output end waypoint same as the input end // waypoint TEST(time_optimal_trajectory_generation, testLastWaypoint) // {