MCPcopy Create free account
hub / github.com/comaps/comaps / EqualBookmarks

Function EqualBookmarks

libs/map/map_tests/bookmarks_test.cpp:1031–1046  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1029 "</kml>";
1030
1031bool EqualBookmarks(Bookmark const & b1, Bookmark const & b2)
1032{
1033 if (b1.GetName() != b2.GetName())
1034 return false;
1035 if (b1.GetDescription() != b2.GetDescription())
1036 return false;
1037 if (b1.GetColor() != b2.GetColor())
1038 return false;
1039 if (b1.GetScale() != b2.GetScale())
1040 return false;
1041 if (!AlmostEqualAbs(b1.GetPivot(), b2.GetPivot(), 1e-6 /* eps*/))
1042 return false;
1043
1044 // do not check timestamp
1045 return true;
1046}
1047} // namespace
1048
1049UNIT_CLASS_TEST(Runner, Bookmarks_SpecialXMLNames)

Callers 1

UNIT_CLASS_TESTFunction · 0.85

Calls 6

AlmostEqualAbsFunction · 0.70
GetNameMethod · 0.45
GetDescriptionMethod · 0.45
GetColorMethod · 0.45
GetScaleMethod · 0.45
GetPivotMethod · 0.45

Tested by

no test coverage detected