mirror of
https://github.com/boostorg/geometry.git
synced 2026-02-10 11:32:15 +00:00
[geometry] merge of Boost.Geometry into release branch
[SVN r84242]
This commit is contained in:
@@ -19,11 +19,12 @@
|
||||
#include <boost/geometry/multi/geometries/multi_linestring.hpp>
|
||||
#include <boost/geometry/multi/geometries/multi_polygon.hpp>
|
||||
|
||||
#include <boost/variant/variant.hpp>
|
||||
|
||||
|
||||
template <typename Geometry>
|
||||
void test_geometry(std::string const& wkt, int expected)
|
||||
void check_geometry(Geometry const& geometry, std::string const& wkt, int expected)
|
||||
{
|
||||
Geometry geometry;
|
||||
bg::read_wkt(wkt, geometry);
|
||||
int detected = bg::num_points(geometry);
|
||||
BOOST_CHECK_MESSAGE(detected == expected,
|
||||
"num_points: " << wkt
|
||||
@@ -31,6 +32,15 @@ void test_geometry(std::string const& wkt, int expected)
|
||||
<< " detected: " << detected);
|
||||
}
|
||||
|
||||
template <typename Geometry>
|
||||
void test_geometry(std::string const& wkt, int expected)
|
||||
{
|
||||
Geometry geometry;
|
||||
bg::read_wkt(wkt, geometry);
|
||||
check_geometry(geometry, wkt, expected);
|
||||
check_geometry(boost::variant<Geometry>(geometry), wkt, expected);
|
||||
}
|
||||
|
||||
|
||||
template <typename Point>
|
||||
void test_all()
|
||||
|
||||
Reference in New Issue
Block a user