]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/libs/geometry/test/algorithms/relational_operations/intersects/intersects_multi.cpp
Add patch for failing prerm scripts
[ceph.git] / ceph / src / boost / libs / geometry / test / algorithms / relational_operations / intersects / intersects_multi.cpp
CommitLineData
7c673cae
FG
1// Boost.Geometry (aka GGL, Generic Geometry Library)
2// Unit Test
3
4// Copyright (c) 2012-2015 Barend Gehrels, Amsterdam, the Netherlands.
5
6// This file was modified by Oracle on 2016.
7// Modifications copyright (c) 2016, Oracle and/or its affiliates.
8// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
9
10// Use, modification and distribution is subject to the Boost Software License,
11// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
12// http://www.boost.org/LICENSE_1_0.txt)
13
14#include <iostream>
15#include <string>
16
17
18#include <geometry_test_common.hpp>
19
20#include "test_intersects.hpp"
21
22#include <boost/geometry.hpp>
23
24#include <boost/geometry/geometries/geometries.hpp>
25#include <boost/geometry/geometries/point_xy.hpp>
26
27template <typename P1, typename P2>
28void test_all()
29{
30 typedef bg::model::polygon<P1> polygon1;
31 typedef bg::model::multi_polygon<polygon1> mp1;
32 typedef bg::model::polygon<P2> polygon2;
33 typedef bg::model::multi_polygon<polygon2> mp2;
34
35 test_geometry<mp1, mp2>("MULTIPOLYGON(((0 0,0 10,10 10,10 0,0 0)))",
36 "MULTIPOLYGON(((0 0,0 10,10 10,10 0,0 0)))",
37 true);
38
39 test_geometry<P1, mp2>("POINT(0 0)",
40 "MULTIPOLYGON(((0 0,0 10,10 10,10 0,0 0)))",
41 true);
42
43}
44
45template <typename P>
46void test_all()
47{
48 test_all<P, P>();
49}
50
51int test_main(int, char* [])
52{
53 //test_all<bg::model::d2::point_xy<float> >();
54 test_all<bg::model::d2::point_xy<double> >();
55 test_all<bg::model::d2::point_xy<double>, bg::model::point<double, 2, bg::cs::cartesian> >();
56
57#ifdef HAVE_TTMATH
58 test_all<bg::model::d2::point_xy<ttmath_big> >();
59#endif
60
61 return 0;
62}
63