summaryrefslogtreecommitdiff
path: root/libs/geometry/test/algorithms/convex_hull.cpp
diff options
context:
space:
mode:
authorLorry Tar Creator <lorry-tar-importer@baserock.org>2015-04-08 03:09:47 +0000
committer <>2015-05-05 14:37:32 +0000
commitf2541bb90af059680aa7036f315f052175999355 (patch)
treea5b214744b256f07e1dc2bd7273035a7808c659f /libs/geometry/test/algorithms/convex_hull.cpp
parented232fdd34968697a68783b3195b1da4226915b5 (diff)
downloadboost-tarball-master.tar.gz
Imported from /home/lorry/working-area/delta_boost-tarball/boost_1_58_0.tar.bz2.HEADboost_1_58_0master
Diffstat (limited to 'libs/geometry/test/algorithms/convex_hull.cpp')
-rw-r--r--libs/geometry/test/algorithms/convex_hull.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/libs/geometry/test/algorithms/convex_hull.cpp b/libs/geometry/test/algorithms/convex_hull.cpp
index dab96ebd8..0ca1bcb7b 100644
--- a/libs/geometry/test/algorithms/convex_hull.cpp
+++ b/libs/geometry/test/algorithms/convex_hull.cpp
@@ -5,6 +5,11 @@
// Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
// Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
+// This file was modified by Oracle on 2015.
+// Modifications copyright (c) 2015 Oracle and/or its affiliates.
+
+// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
+
// Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
// (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
@@ -46,6 +51,24 @@ void test_all()
test_geometry<bg::model::box<P> >("box(0 0,2 2)", 4, 5, 4);
+ // https://svn.boost.org/trac/boost/ticket/6443
+ {
+ test_geometry<bg::model::ring<P> >(
+ "polygon((0 0, 2 0))", // note that this polygon is very invalid
+ 2, 4, 0, 4);
+ }
+
+ // degenerated hulls
+ test_geometry<bg::model::multi_point<P> >(
+ "multipoint(0 0)",
+ 1, 4, 0, 0);
+ test_geometry<bg::model::multi_point<P> >(
+ "multipoint(0 0, 2 0)",
+ 2, 4, 0, 4);
+ test_geometry<bg::model::linestring<P> >(
+ "linestring(0 0, 2 0)",
+ 2, 4, 0, 4);
+
test_empty_input<bg::model::linestring<P> >();
test_empty_input<bg::model::ring<P> >();
test_empty_input<bg::model::polygon<P> >();