mirror of
https://github.com/boostorg/geometry.git
synced 2025-05-09 23:24:02 +00:00
[test] Update tests WRT recent changes related to CS-specific strategies propagation.
This commit is contained in:
parent
d772e36632
commit
970bce222f
@ -3,6 +3,10 @@
|
||||
|
||||
// Copyright (c) 2011-2015 Adam Wulkiewicz, Lodz, Poland.
|
||||
|
||||
// This file was modified by Oracle on 2019.
|
||||
// Modifications copyright (c) 2019, Oracle and/or its affiliates.
|
||||
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
|
||||
|
||||
// Use, modification and distribution is subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
@ -922,10 +926,10 @@ struct covered_by_impl
|
||||
|
||||
BOOST_FOREACH(Value const& v, input)
|
||||
{
|
||||
if ( bg::covered_by(
|
||||
bgi::detail::return_ref_or_bounds(
|
||||
tree.indexable_get()(v)),
|
||||
qbox) )
|
||||
if ( bgi::detail::covered_by_bounds(
|
||||
tree.indexable_get()(v),
|
||||
qbox,
|
||||
bgi::detail::get_strategy(tree.parameters())) )
|
||||
{
|
||||
expected_output.push_back(v);
|
||||
}
|
||||
@ -1839,7 +1843,8 @@ void test_rtree_bounds(Parameters const& parameters, Allocator const& allocator)
|
||||
|
||||
generate::rtree(t, input, qbox);
|
||||
|
||||
b = bgi::detail::rtree::values_box<B>(input.begin(), input.end(), t.indexable_get());
|
||||
b = bgi::detail::rtree::values_box<B>(input.begin(), input.end(), t.indexable_get(),
|
||||
bgi::detail::get_strategy(parameters));
|
||||
|
||||
BOOST_CHECK(bg::equals(t.bounds(), b));
|
||||
BOOST_CHECK(bg::equals(t.bounds(), bgi::bounds(t)));
|
||||
@ -1851,7 +1856,8 @@ void test_rtree_bounds(Parameters const& parameters, Allocator const& allocator)
|
||||
input.pop_back();
|
||||
}
|
||||
|
||||
b = bgi::detail::rtree::values_box<B>(input.begin(), input.end(), t.indexable_get());
|
||||
b = bgi::detail::rtree::values_box<B>(input.begin(), input.end(), t.indexable_get(),
|
||||
bgi::detail::get_strategy(parameters));
|
||||
|
||||
BOOST_CHECK(bg::equals(t.bounds(), b));
|
||||
|
||||
|
@ -1,12 +1,13 @@
|
||||
// Boost.Geometry (aka GGL, Generic Geometry Library)
|
||||
|
||||
// Copyright (c) 2015, Oracle and/or its affiliates.
|
||||
// Copyright (c) 2015, 2019, Oracle and/or its affiliates.
|
||||
|
||||
// Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
|
||||
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
|
||||
|
||||
// Licensed under the Boost Software License version 1.0.
|
||||
// http://www.boost.org/users/license.html
|
||||
|
||||
// Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
|
||||
|
||||
#ifndef BOOST_GEOMETRY_TEST_CHECK_TURN_LESS_HPP
|
||||
#define BOOST_GEOMETRY_TEST_CHECK_TURN_LESS_HPP
|
||||
|
||||
@ -86,11 +87,13 @@ struct check_turn_less
|
||||
bg::detail::get_turns::get_turn_info_type
|
||||
<
|
||||
Geometry1, Geometry2, assign_policy<>
|
||||
>,
|
||||
robust_policy_type
|
||||
>
|
||||
> get_turns_type;
|
||||
|
||||
typedef typename get_turns_type::turn_info turn_info;
|
||||
typedef typename get_turns_type::template turn_info_type
|
||||
<
|
||||
strategy_type, robust_policy_type
|
||||
>::type turn_info;
|
||||
|
||||
typedef std::vector<turn_info> turns_container;
|
||||
|
||||
|
@ -1,12 +1,13 @@
|
||||
// Boost.Geometry (aka GGL, Generic Geometry Library)
|
||||
|
||||
// Copyright (c) 2014, Oracle and/or its affiliates.
|
||||
// Copyright (c) 2014, 2019, Oracle and/or its affiliates.
|
||||
|
||||
// Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
|
||||
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
|
||||
|
||||
// Licensed under the Boost Software License version 1.0.
|
||||
// http://www.boost.org/users/license.html
|
||||
|
||||
// Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
|
||||
|
||||
#ifndef BOOST_GEOMETRY_TEST_GET_TURNS_LL_INVARIANCE_HPP
|
||||
#define BOOST_GEOMETRY_TEST_GET_TURNS_LL_INVARIANCE_HPP
|
||||
|
||||
@ -91,10 +92,15 @@ public:
|
||||
static inline void apply(Linear1 const& lineargeometry1,
|
||||
Linear2 const& lineargeometry2)
|
||||
{
|
||||
typedef typename bg::strategy::relate::services::default_strategy
|
||||
<
|
||||
Linear1, Linear2
|
||||
>::type strategy_type;
|
||||
|
||||
typedef typename bg_detail::relate::turns::get_turns
|
||||
<
|
||||
Linear1, Linear2
|
||||
>::turn_info turn_info;
|
||||
>::template turn_info_type<strategy_type>::type turn_info;
|
||||
|
||||
typedef std::vector<turn_info> turns_container;
|
||||
|
||||
|
@ -3,8 +3,8 @@
|
||||
|
||||
// Copyright (c) 2010-2012 Barend Gehrels, Amsterdam, the Netherlands.
|
||||
|
||||
// This file was modified by Oracle on 2014.
|
||||
// Modifications copyright (c) 2014 Oracle and/or its affiliates.
|
||||
// This file was modified by Oracle on 2014, 2019.
|
||||
// Modifications copyright (c) 2014, 2019 Oracle and/or its affiliates.
|
||||
|
||||
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
|
||||
|
||||
@ -72,7 +72,7 @@ void test_point_in_polygon(std::string const& case_id,
|
||||
bool expected,
|
||||
bool use_within = true)
|
||||
{
|
||||
BOOST_CONCEPT_ASSERT( (bg::concepts::WithinStrategyPolygonal<Strategy>) );
|
||||
BOOST_CONCEPT_ASSERT( (bg::concepts::WithinStrategyPolygonal<Point, Polygon, Strategy>) );
|
||||
bool detected = use_within ?
|
||||
bg::within(point, polygon, strategy) :
|
||||
bg::covered_by(point, polygon, strategy);
|
||||
|
Loading…
x
Reference in New Issue
Block a user