mirror of
https://github.com/boostorg/geometry.git
synced 2026-02-12 12:12:10 +00:00
[equals] use collected_vector as a type, no specialization (review result)
This commit is contained in:
@@ -19,4 +19,5 @@ test-suite boost-geometry-algorithms-equals
|
||||
[ run equals.cpp : : : : algorithms_equals ]
|
||||
[ run equals_multi.cpp : : : : algorithms_equals_multi ]
|
||||
[ run equals_on_spheroid.cpp : : : : algorithms_equals_on_spheroid ]
|
||||
[ run equals_sph.cpp : : : : algorithms_equals_sph ]
|
||||
;
|
||||
|
||||
@@ -234,7 +234,6 @@ BOOST_AUTO_TEST_CASE( equals_segment_segment_geo )
|
||||
test_segment_segment<bgm::point<long double, 2, cs_type> >("geo");
|
||||
}
|
||||
|
||||
#if defined(BOOST_GEOMETRY_TEST_FAILURES)
|
||||
// This version uses collect_vectors (because its side
|
||||
// strategy is spherical_side_formula) and fails
|
||||
BOOST_AUTO_TEST_CASE( equals_ring_ring_se)
|
||||
@@ -247,7 +246,6 @@ BOOST_AUTO_TEST_CASE( equals_ring_ring_se)
|
||||
"POLYGON((10 50,10 51,11 50,10 50))",
|
||||
true);
|
||||
}
|
||||
#endif
|
||||
|
||||
BOOST_AUTO_TEST_CASE( equals_ring_ring_geo )
|
||||
{
|
||||
|
||||
@@ -147,5 +147,13 @@ int test_main( int , char* [] )
|
||||
{
|
||||
test_all<bg::model::point<double, 2, bg::cs::spherical_equatorial<bg::degree> > >();
|
||||
|
||||
// TODO: the polar version needs several traits more, for example in cs_tag,
|
||||
// to compile properly.
|
||||
//test_all<bg::model::point<double, 2, bg::cs::polar<bg::degree> > >();
|
||||
|
||||
#if defined(BOOST_GEOMETRY_TEST_FAILURES)
|
||||
test_all<bg::model::point<double, 2, bg::cs::geographic<bg::degree> > >();
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -26,7 +26,10 @@
|
||||
#include <boost/variant/variant.hpp>
|
||||
|
||||
|
||||
struct no_strategy {};
|
||||
struct no_strategy
|
||||
{
|
||||
using cs_tag = void;
|
||||
};
|
||||
|
||||
template <typename Geometry1, typename Geometry2, typename Strategy>
|
||||
bool call_equals(Geometry1 const& geometry1,
|
||||
@@ -60,7 +63,9 @@ void check_geometry(Geometry1 const& geometry1,
|
||||
<< " equals: " << wkt1
|
||||
<< " to " << wkt2
|
||||
<< " -> Expected: " << expected
|
||||
<< " detected: " << detected);
|
||||
<< " detected: " << detected
|
||||
<< " strategy: " << typeid(Strategy).name()
|
||||
<< " cs: " << typeid(typename Strategy::cs_tag).name());
|
||||
|
||||
detected = call_equals(geometry2, geometry1, strategy);
|
||||
|
||||
@@ -69,7 +74,8 @@ void check_geometry(Geometry1 const& geometry1,
|
||||
<< " equals: " << wkt2
|
||||
<< " to " << wkt1
|
||||
<< " -> Expected: " << expected
|
||||
<< " detected: " << detected);
|
||||
<< " strategy: " << typeid(Strategy).name()
|
||||
<< " cs: " << typeid(typename Strategy::cs_tag).name());
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user