23 #include "gtest/gtest.h" 30 using ::cartographer::mapping::TrajectoryNode;
31 const TrajectoryNode trajectory_node{
32 std::make_shared<TrajectoryNode::Data>(TrajectoryNode::Data{
33 ::cartographer::common::FromUniversal(52),
35 {Eigen::Vector3f(-30.f, 1.f, 0.f),
36 Eigen::Vector3f(50.f, -10.f, 0.f)},
39 Eigen::Vector3f::Zero(), {}, {}}),
42 constexpr
double kResolution = 0.05;
43 const ::cartographer::mapping_2d::MapLimits limits =
45 constexpr
float kPaddingAwareTolerance = 5 * kResolution;
46 EXPECT_NEAR(50.f, limits.max().x(), kPaddingAwareTolerance);
47 EXPECT_NEAR(1.f, limits.max().y(), kPaddingAwareTolerance);
48 EXPECT_LT(200, limits.cell_limits().num_x_cells);
49 EXPECT_LT(1600, limits.cell_limits().num_y_cells);
50 EXPECT_GT(400, limits.cell_limits().num_x_cells);
51 EXPECT_GT(2000, limits.cell_limits().num_y_cells);
::cartographer::mapping_2d::MapLimits ComputeMapLimits(const double resolution, const std::vector<::cartographer::mapping::TrajectoryNode > &trajectory_nodes)
TEST(ActionClientDestruction, persistent_goal_handles_1)