mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-22 06:03:45 +00:00
ADL for AlmostEqual* and use math:: instead of base:: (#9634)
* ADL for AlmostEqual* and use math:: instead of base:: Signed-off-by: Alexander Borsuk <me@alex.bio>
This commit is contained in:
committed by
Konstantin Pastbin
parent
82133c5743
commit
30718e106e
@@ -98,7 +98,7 @@ void RoutingTest::TestRouters(m2::PointD const & startPos, m2::PointD const & fi
|
||||
}
|
||||
|
||||
double constexpr kEpsilon = 1e-6;
|
||||
TEST(base::AlmostEqualAbs(routeFoundByAstar.GetTotalDistanceMeters(),
|
||||
TEST(AlmostEqualAbs(routeFoundByAstar.GetTotalDistanceMeters(),
|
||||
routeFoundByAstarBidirectional.GetTotalDistanceMeters(), kEpsilon),
|
||||
());
|
||||
}
|
||||
@@ -160,8 +160,8 @@ void TestRouter(routing::IRouter & router, m2::PointD const & startPos,
|
||||
TEST(route.IsValid(), ());
|
||||
m2::PolylineD const & poly = route.GetPoly();
|
||||
TEST_GREATER(poly.GetSize(), 0, ());
|
||||
TEST(base::AlmostEqualAbs(poly.Front(), startPos, kMwmPointAccuracy), ());
|
||||
TEST(base::AlmostEqualAbs(poly.Back(), finalPos, kMwmPointAccuracy), ());
|
||||
TEST(AlmostEqualAbs(poly.Front(), startPos, kMwmPointAccuracy), ());
|
||||
TEST(AlmostEqualAbs(poly.Back(), finalPos, kMwmPointAccuracy), ());
|
||||
LOG(LINFO, ("Route polyline size:", route.GetPoly().GetSize()));
|
||||
LOG(LINFO, ("Route distance, meters:", route.GetTotalDistanceMeters()));
|
||||
LOG(LINFO, ("Elapsed, seconds:", elapsedSec));
|
||||
|
||||
Reference in New Issue
Block a user