22 #include "google/protobuf/util/message_differencer.h" 23 #include "gtest/gtest.h" 29 TEST(PoseGraph, SerializeConstraint) {
32 ::google::protobuf::RepeatedPtrField<proto::PoseGraph::Constraint>
34 *constraint_protos.Add() = expected_constraint;
35 PoseGraph::Constraint constraint =
FromProto(constraint_protos).front();
36 EXPECT_TRUE(google::protobuf::util::MessageDifferencer::Equals(
37 expected_constraint,
ToProto(constraint)));
PoseGraph::Constraint::Tag FromProto(const proto::PoseGraph::Constraint::Tag &proto)
proto::PoseGraph::Constraint CreateFakeConstraint(const proto::Node &node, const proto::Submap &submap)
proto::Submap CreateFakeSubmap3D(int trajectory_id, int submap_index)
proto::Node CreateFakeNode(int trajectory_id, int node_index)
proto::MapLimits ToProto(const MapLimits &map_limits)
TEST(TrajectoryConnectivityStateTest, UnknownTrajectory)