diff --git a/include/boost/geometry/algorithms/detail/overlay/get_turn_info.hpp b/include/boost/geometry/algorithms/detail/overlay/get_turn_info.hpp index da3107f0c..4dd823f96 100644 --- a/include/boost/geometry/algorithms/detail/overlay/get_turn_info.hpp +++ b/include/boost/geometry/algorithms/detail/overlay/get_turn_info.hpp @@ -77,17 +77,10 @@ struct policy_verify_all static bool const use_handle_imperfect_touch = true; }; - -#if defined(BOOST_GEOMETRY_USE_RESCALING) -using verify_policy_aa = policy_verify_nothing; -#else using verify_policy_aa = policy_verify_all; -#endif - using verify_policy_ll = policy_verify_nothing; using verify_policy_la = policy_verify_nothing; - struct base_turn_handler { // Returns true if both sides are opposite diff --git a/include/boost/geometry/strategies/cartesian/intersection.hpp b/include/boost/geometry/strategies/cartesian/intersection.hpp index 0d612f0ea..87d99101e 100644 --- a/include/boost/geometry/strategies/cartesian/intersection.hpp +++ b/include/boost/geometry/strategies/cartesian/intersection.hpp @@ -239,13 +239,10 @@ struct cartesian_segments { assign_b(point, a, b); } - -#ifndef BOOST_GEOMETRY_USE_RESCALING // Verify nearly collinear cases (the threshold is arbitrary // but influences performance). If the intersection is located // outside the segments, then it should be moved. - if (ra.possibly_collinear(1.0e-3) - && rb.possibly_collinear(1.0e-3)) + if (ra.possibly_collinear(1.0e-3) && rb.possibly_collinear(1.0e-3)) { // The segments are nearly collinear and because of the calculation // method with very small denominator, the IP appears outside the @@ -255,7 +252,6 @@ struct cartesian_segments assign_if_exceeds(point, a); assign_if_exceeds(point, b); } -#endif } CoordinateType dx_a, dy_a; diff --git a/include/boost/geometry/strategies/cartesian/turn_in_ring_winding.hpp b/include/boost/geometry/strategies/cartesian/turn_in_ring_winding.hpp index fcbc03bca..ea06756d9 100644 --- a/include/boost/geometry/strategies/cartesian/turn_in_ring_winding.hpp +++ b/include/boost/geometry/strategies/cartesian/turn_in_ring_winding.hpp @@ -77,9 +77,6 @@ public: int count_on_edge{0}; CalculationType edge_min_fraction{(std::numeric_limits::max)()}; -#if defined(BOOST_GEOMETRY_USE_RESCALING) - CalculationType inside_min_measure{(std::numeric_limits::max)()}; -#endif inline bool is_inside() const { @@ -91,9 +88,6 @@ public: return count_on_origin == 0 && (count_on_offsetted > 0 || (count_on_edge > 0 && edge_min_fraction < 1.0e-3) -#if defined(BOOST_GEOMETRY_USE_RESCALING) - || (count < 0 && inside_min_measure < 1.0e-5) -#endif ); } @@ -186,15 +180,6 @@ public: { apply_on_boundary(point, s1, s2, place_on_ring, the_state); } -#if defined(BOOST_GEOMETRY_USE_RESCALING) - else if (side == -1) - { - auto const line = detail::make::make_infinite_line(s1, s2); - auto const value = -arithmetic::side_value(line, point); - if (value > 0 && value < the_state.inside_min_measure) { the_state.inside_min_measure = value; } - - } -#endif } if (in_horizontal_range) diff --git a/test/algorithms/buffer/buffer_countries.cpp b/test/algorithms/buffer/buffer_countries.cpp index 8e8a7e1b2..4964e0a59 100644 --- a/test/algorithms/buffer/buffer_countries.cpp +++ b/test/algorithms/buffer/buffer_countries.cpp @@ -103,10 +103,8 @@ void test_one(std::string const& caseid, std::string const& wkt, double expected settings.tolerance = 10000.0; -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) // in case robustness policies are changed, areas should be adapted settings.tolerance = boost::starts_with(caseid, "no") ? 200000.0 : 100000.0; -#endif test_one(caseid, wkt, join_round, end_flat, expected_area, distance * 1000.0, settings); @@ -213,7 +211,7 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(1, BG_NO_FAILURES, 2, BG_NO_FAILURES); + BoostGeometryWriteExpectedFailures(BG_NO_FAILURES, 2, BG_NO_FAILURES); #endif return 0; diff --git a/test/algorithms/buffer/buffer_linestring.cpp b/test/algorithms/buffer/buffer_linestring.cpp index 45bd06cc2..259a2e7e9 100644 --- a/test/algorithms/buffer/buffer_linestring.cpp +++ b/test/algorithms/buffer/buffer_linestring.cpp @@ -330,7 +330,6 @@ void test_all() test_one("issue_803", issue_803, join_round(36), end_round(36), 1664.0528, 10.0); } -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) { using bg::strategy::buffer::join_round; using bg::strategy::buffer::end_round; @@ -338,7 +337,6 @@ void test_all() test_one("issue_988_b", issue_988, join_round(32), end_round(32), 0.0029614, 0.0101); test_one("issue_988_c", issue_988, join_round(32), end_round(32), 0.0031514, 0.011); } -#endif { using bg::strategy::buffer::join_round; @@ -366,24 +364,17 @@ void test_all() test_one("mysql_23023665_1", mysql_23023665, join_round32, end_flat, 459.1051, 10); test_one("mysql_23023665_2", mysql_23023665, join_round32, end_flat, 6877.7097, 50); - -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) test_one("mysql_25662426", mysql_25662426, join_round32, end_round32, 1, 0, 1660.6673, 10); -#endif + // Test behaviour with different buffer sizes, generating internally turns on different locations test_one("mysql_25662426a_05", mysql_25662426a, join_round32, end_round32, 27.6156, 0.5); test_one("mysql_25662426a_1", mysql_25662426a, join_round32, end_round32, 54.9018, 1.0); test_one("mysql_25662426a_2", mysql_25662426a, join_round32, end_round32, 103.6072, 2.0); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) test_one("mysql_25662426a_3", mysql_25662426a, join_round32, end_round32, 152.1163, 3.0); -#endif test_one("mysql_25662426a_4", mysql_25662426a, join_round32, end_round32, 206.4831, 4.0); test_one("mysql_25662426a_5", mysql_25662426a, join_round32, end_round32, 266.8505, 5.0); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) test_one("mysql_25662426a_10", mysql_25662426a, join_round32, end_round32, 660.7355, 10.0); -#endif - test_one("mysql_25662426a_05", mysql_25662426a, join_round32, end_flat, 26.8352, 0.5); test_one("mysql_25662426a_1", mysql_25662426a, join_round32, end_flat, 53.3411, 1.0); test_one("mysql_25662426a_2", mysql_25662426a, join_round32, end_flat, 97.3644, 2.0); @@ -480,7 +471,7 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(2, 4, 11, 3); + BoostGeometryWriteExpectedFailures(4, 11, 3); #endif return 0; diff --git a/test/algorithms/buffer/buffer_linestring_aimes.cpp b/test/algorithms/buffer/buffer_linestring_aimes.cpp index fa0992d29..ec5983527 100644 --- a/test/algorithms/buffer/buffer_linestring_aimes.cpp +++ b/test/algorithms/buffer/buffer_linestring_aimes.cpp @@ -257,7 +257,7 @@ void test_aimes() double const aimes_width = width / 1000000.0; for (int i = 0; i < n; i++) { -#if defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) +#if defined(BOOST_GEOMETRY_TEST_FAILURES) // There are 4 false positives bool const possible_invalid = width == 18 && (i == 75 || i == 80 || i == 140); settings.set_test_validity(! possible_invalid); @@ -297,7 +297,7 @@ int test_main(int, char* []) #if defined(BOOST_GEOMETRY_TEST_FAILURES) // Type float is not supported for these cases. // Type double has (judging the svg) 4 false negatives for validity - BoostGeometryWriteExpectedFailures(0, 0, 0, 0); + BoostGeometryWriteExpectedFailures(0, 0, 0); #endif return 0; diff --git a/test/algorithms/buffer/buffer_multi_linestring.cpp b/test/algorithms/buffer/buffer_multi_linestring.cpp index 55b3cbcdc..abf3f6ea7 100644 --- a/test/algorithms/buffer/buffer_multi_linestring.cpp +++ b/test/algorithms/buffer/buffer_multi_linestring.cpp @@ -172,11 +172,7 @@ void test_all() test_one("mysql_23023665_1", mysql_23023665_1, join_round32, end_round32, 1, 1, 186.5504, 1.0); test_one("touching1_1", - touching1, join_round32, end_round32, 2, 0, 78.70773, 1.0 -#if defined(BOOST_GEOMETRY_USE_RESCALING) - , ut_settings::ignore_validity() // false positive, due to rescaling. As we remove it, it is gone -#endif - ); + touching1, join_round32, end_round32, 2, 0, 78.70773, 1.0); test_one("touching2_1", touching2, join_round32, end_round32, 1, 1, 107.8991, 1.0); test_one("mysql_23023665_1_09", @@ -239,7 +235,7 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(9, 6, 9, 3); + BoostGeometryWriteExpectedFailures(6, 9, 3); #endif return 0; } diff --git a/test/algorithms/buffer/buffer_multi_polygon.cpp b/test/algorithms/buffer/buffer_multi_polygon.cpp index 4b87a5378..a7af1cfce 100644 --- a/test/algorithms/buffer/buffer_multi_polygon.cpp +++ b/test/algorithms/buffer/buffer_multi_polygon.cpp @@ -547,11 +547,7 @@ void test_all() test_one("rt_p14", rt_p14, join_miter, end_flat, 20.8284, 1.0); test_one("rt_p15", rt_p15, join_miter, end_flat, 23.6569, 1.0); test_one("rt_p16", rt_p16, join_miter, end_flat, 23.4853, 1.0); - -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Fails with rescaling after correcting the tolerance in sort_by_side test_one("rt_p17", rt_p17, join_miter, end_flat, 25.3137, 1.0); -#endif test_one("rt_p18", rt_p18, join_miter, end_flat, 23.3137, 1.0); test_one("rt_p19", rt_p19, join_miter, end_flat, 25.5637, 1.0); test_one("rt_p20", rt_p20, join_miter, end_flat, 25.4853, 1.0); @@ -577,15 +573,11 @@ void test_all() test_one("rt_u4", rt_u4, join_round, end_flat, 126.9268, 1.0); test_one("rt_u5", rt_u5, join_round, end_flat, 78.4906, 1.0); test_one("rt_u6", rt_u6, join_round, end_flat, 115.4461, 1.0); - test_one("rt_u7", rt_u7, join_miter, end_flat, 42.6421, 1.0); test_one("rt_u7", rt_u7, join_round, end_flat, 35.6233, 1.0); test_one("rt_u7_rough", rt_u7, join_round_rough, end_flat, {35.1675, 35.2290}, 1.0); - test_one("rt_u8", rt_u8, join_miter, end_flat, 70.9142, 1.0); test_one("rt_u9", rt_u9, join_miter, end_flat, 59.3063, 1.0); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Fails with rescaling after removing pretraversal test_one("rt_u10", rt_u10, join_miter, end_flat, 144.0858, 1.0); test_one("rt_u10_51", rt_u10, join_miter, end_flat, 0.16738, -0.51); test_one("rt_u10_c_51", rt_u10_c, join_miter, end_flat, 0.066952, -0.51); @@ -593,21 +585,12 @@ void test_all() // TODO: invalid - making a bow-tie test_one("rt_u10_50", rt_u10, join_miter, end_flat, 0.214466, -0.50, ut_settings::ignore_validity()); test_one("rt_u10_45", rt_u10, join_miter, end_flat, 1.3000, -0.45); -#endif test_one("rt_u10_25", rt_u10, join_miter, end_flat, 9.6682, -0.25); - test_one("rt_u11", rt_u11, join_miter, end_flat, 131.3995, 1.0); test_one("rt_u11_50", rt_u11, join_miter, end_flat, 0.04289, -0.50); test_one("rt_u11_25", rt_u11, join_miter, end_flat, 10.1449, -0.25); - -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Fails with rescaling after correcting the tolerance in sort_by_side test_one("rt_u12", rt_u12, join_miter, end_flat, 142.1348, 1.0); -#endif -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Fails with rescaling in combination with get_clusters test_one("rt_u13", rt_u13, join_miter, end_flat, 115.4853, 1.0); -#endif test_one("rt_v1", rt_v1, join_round32, end_flat, 26.9994, 1.0); test_one("rt_v2", rt_v2, join_round32, end_flat, 47.3510, 1.0); @@ -655,10 +638,7 @@ void test_all() test_one("nores_b03e", nores_b03e, join_round32, end_flat, 14.4877, 1.0); test_one("res_ebc4", res_ebc4, join_round32, end_flat, 43.8877, 1.0); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Erroneous case with rescaling test_one("res_8618", res_8618, join_round32, end_flat, 48.1085, 1.0); -#endif test_one("res_3b4d", res_3b4d, join_round32, end_flat, 48.4739, 1.0); test_one("neighbouring_small", @@ -704,7 +684,7 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(3, 1, 3, 3); + BoostGeometryWriteExpectedFailures(1, 3, 3); #endif return 0; diff --git a/test/algorithms/buffer/buffer_polygon.cpp b/test/algorithms/buffer/buffer_polygon.cpp index 4fa2d6285..392ac1307 100644 --- a/test/algorithms/buffer/buffer_polygon.cpp +++ b/test/algorithms/buffer/buffer_polygon.cpp @@ -948,7 +948,7 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(2, 1, 9, 1); + BoostGeometryWriteExpectedFailures(1, 9, 1); #endif test_different(); diff --git a/test/algorithms/overlay/overlay.cpp b/test/algorithms/overlay/overlay.cpp index 84a84e7b3..9a51a7cf3 100644 --- a/test/algorithms/overlay/overlay.cpp +++ b/test/algorithms/overlay/overlay.cpp @@ -364,9 +364,6 @@ void test_overlay(std::string const& caseid, << "_" << string_from_type::type>::name() << (ccw ? "_ccw" : "") << (open ? "_open" : "") -#if defined(BOOST_GEOMETRY_USE_RESCALING) - << "_rescaled" -#endif << ".svg"; std::ofstream svg(filename.str().c_str()); diff --git a/test/algorithms/set_operations/difference/difference.cpp b/test/algorithms/set_operations/difference/difference.cpp index 98a7f69a6..194906789 100644 --- a/test/algorithms/set_operations/difference/difference.cpp +++ b/test/algorithms/set_operations/difference/difference.cpp @@ -685,7 +685,7 @@ int test_main(int, char* []) // Not yet fully tested for float and long double. // The difference algorithm can generate (additional) slivers // Many of the failures are self-intersection points. - BoostGeometryWriteExpectedFailures(15, 5, 17, 10); + BoostGeometryWriteExpectedFailures(5, 17, 10); #endif return 0; diff --git a/test/algorithms/set_operations/difference/difference_multi.cpp b/test/algorithms/set_operations/difference/difference_multi.cpp index d1d89a99c..2472e2221 100644 --- a/test/algorithms/set_operations/difference/difference_multi.cpp +++ b/test/algorithms/set_operations/difference/difference_multi.cpp @@ -525,7 +525,7 @@ int test_main(int, char* []) #if defined(BOOST_GEOMETRY_TEST_FAILURES) // Not yet fully tested for float. // The difference algorithm can generate (additional) slivers - BoostGeometryWriteExpectedFailures(24, 11, 21, 7); + BoostGeometryWriteExpectedFailures(11, 21, 7); #endif return 0; diff --git a/test/algorithms/set_operations/difference/test_difference.hpp b/test/algorithms/set_operations/difference/test_difference.hpp index d9e13a210..08906be13 100644 --- a/test/algorithms/set_operations/difference/test_difference.hpp +++ b/test/algorithms/set_operations/difference/test_difference.hpp @@ -131,9 +131,6 @@ void difference_output(std::string const& caseid, G1 const& g1, G2 const& g2, Ou << string_from_type::name() << (ccw ? "_ccw" : "") << (open ? "_open" : "") -#if defined(BOOST_GEOMETRY_USE_RESCALING) - << "_rescaled" -#endif << ".svg"; std::ofstream svg(filename.str().c_str()); @@ -258,18 +255,6 @@ std::string test_difference(std::string const& caseid, G1 const& g1, G2 const& g #if ! defined(BOOST_GEOMETRY_NO_BOOST_TEST) -#if defined(BOOST_GEOMETRY_USE_RESCALING) - if (expected_point_count >= 0) - { - std::size_t const n = bg::num_points(result); - BOOST_CHECK_MESSAGE(bg::math::abs(int(n) - expected_point_count) < 3, - "difference: " << caseid - << " #points expected: " << expected_point_count - << " detected: " << n - << " type: " << (type_for_assert_message()) - ); - } -#endif if (! expected_count.empty()) { diff --git a/test/algorithms/set_operations/intersection/intersection.cpp b/test/algorithms/set_operations/intersection/intersection.cpp index 27a363594..684e37c9a 100644 --- a/test/algorithms/set_operations/intersection/intersection.cpp +++ b/test/algorithms/set_operations/intersection/intersection.cpp @@ -151,13 +151,9 @@ void test_areal() simplex_normal[0], simplex_normal[1], 1, 7, 5.47363293); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Fails if rescaling is used in combination with get_clusters, because a cluster is generated - // and use as the start of the traversal test_one("distance_zero", distance_zero[0], distance_zero[1], 1, 0, 0.29516139); -#endif test_one("equal_holes_disjoint", equal_holes_disjoint[0], equal_holes_disjoint[1], @@ -182,10 +178,10 @@ void test_areal() pie_2_3_23_0[0], pie_2_3_23_0[1], 1, 4, 163292.679042133, ut_settings(0.1)); -#if defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) +#if defined(BOOST_GEOMETRY_TEST_FAILURES) TEST_INTERSECTION(isovist, 1, 19, expectation_limits(88.19202, 88.19206)); #else - // Reported as invalid without rescaling and get_clusters + // Reported as invalid TEST_INTERSECTION_IGNORE(isovist, 1, 19, expectation_limits(88.19202, 88.19206)); #endif @@ -296,20 +292,14 @@ void test_areal() 1, 8, 129.90381, settings); } -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // With rescaling the output is empty TEST_INTERSECTION(issue_548, 1, -1, expectation_limits(1958821942, 1958824416)); -#endif TEST_INTERSECTION(issue_566_a, 1, -1, 70.7107); TEST_INTERSECTION(issue_566_b, 1, -1, 70.7107); TEST_INTERSECTION(issue_838, 1, -1, (expectation_limits{0.6582, 0.6650})); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // With rescaling the output is wrong TEST_INTERSECTION(issue_861, 1, -1, 1.4715007684573677693e-10); -#endif TEST_INTERSECTION(issue_1229, 0, -1, 0); @@ -852,7 +842,7 @@ int test_main(int, char* []) #if defined(BOOST_GEOMETRY_TEST_FAILURES) // llb_touch generates a polygon with 1 point and is therefore invalid everywhere // TODO: this should be easy to fix - BoostGeometryWriteExpectedFailures(6, 2, 7, 1); + BoostGeometryWriteExpectedFailures(2, 7, 1); #endif return 0; diff --git a/test/algorithms/set_operations/intersection/intersection_multi.cpp b/test/algorithms/set_operations/intersection/intersection_multi.cpp index 81bc38121..37ef6c4a2 100644 --- a/test/algorithms/set_operations/intersection/intersection_multi.cpp +++ b/test/algorithms/set_operations/intersection/intersection_multi.cpp @@ -134,15 +134,9 @@ void test_areal() test_one("case_107_multi_inv_b", case_107_multi[1], case_107_multi[2], 3, 13, 3.0); - -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - { - // Rescaling misses one intersection - test_one("case_108_multi", - case_108_multi[0], case_108_multi[1], - 7, -1, 7.5); - } -#endif + test_one("case_108_multi", + case_108_multi[0], case_108_multi[1], + 7, -1, 7.5); TEST_INTERSECTION(case_123_multi, 3, 13, 1.875); TEST_INTERSECTION(case_124_multi, 2, 13, 2.0625); @@ -323,23 +317,15 @@ void test_areal() TEST_INTERSECTION(case_recursive_boxes_82, 5, -1, 8.5); TEST_INTERSECTION(case_recursive_boxes_83, 5, -1, 10.25); TEST_INTERSECTION(case_recursive_boxes_84, 1, -1, 0.5); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) TEST_INTERSECTION(case_recursive_boxes_85, 1, -1, 0.25); -#endif TEST_INTERSECTION(case_recursive_boxes_86, 0, -1, 0.0); TEST_INTERSECTION(case_recursive_boxes_87, 0, -1, 0.0); TEST_INTERSECTION(case_recursive_boxes_88, 4, -1, 3.5); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) TEST_INTERSECTION(case_precision_m1, 1, -1, 14.0); TEST_INTERSECTION(case_precision_m2, 2, -1, 15.25); TEST_INTERSECTION_REV(case_precision_m1, 1, -1, 14.0); TEST_INTERSECTION_REV(case_precision_m2, 2, -1, 15.25); -#else - // Validity: false positives (very small triangles looking like a line) - TEST_INTERSECTION_IGNORE(case_precision_m1, 1, -1, 14.0); - TEST_INTERSECTION_IGNORE(case_precision_m2, 2, -1, 15.25); -#endif test_one("ggl_list_20120915_h2_a", ggl_list_20120915_h2[0], ggl_list_20120915_h2[1], @@ -363,20 +349,13 @@ void test_areal() TEST_INTERSECTION(ticket_12503, 2, 13, 17.375); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Result is wrong with rescaling TEST_INTERSECTION(issue_630_a, 1, -1, 0.1770); -#endif TEST_INTERSECTION(issue_630_b, 1, -1, expectation_limits(0.1713911, 0.1714)); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // Result is missing with rescaling TEST_INTERSECTION(issue_630_c, 1, -1, 0.1770); - // Result is missing with rescaling TEST_INTERSECTION(issue_643, 1, -1, 3.4615); -#endif TEST_INTERSECTION(issue_869_c, 3, -1, 3600); @@ -501,17 +480,12 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(9, 1, 2, 1); + BoostGeometryWriteExpectedFailures(1, 2, 1); #endif return 0; } - -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - -//failing with rescaling on - // https://github.com/boostorg/geometry/issues/630 void testIntersection(const std::string& polyString, const std::string& multiPolyString) @@ -551,5 +525,3 @@ BOOST_AUTO_TEST_CASE(Test3) testIntersection("POLYGON((-0.3 -0.1475,-0.3 +0.1475,+0.3 +0.1475,+0.3 -0.1475,-0.3 -0.1475))", "MULTIPOLYGON(((-0.9099999999999999 +0.4625,-0.1912799075873667 +1.181220092412633,+0.9707630752925609 +0.01917710953270602,+0.2520429828799277 -0.6995429828799273,-0.9099999999999999 +0.4625)))"); } - -#endif diff --git a/test/algorithms/set_operations/union/test_union.hpp b/test/algorithms/set_operations/union/test_union.hpp index 21ae98c23..dfa48b8b9 100644 --- a/test/algorithms/set_operations/union/test_union.hpp +++ b/test/algorithms/set_operations/union/test_union.hpp @@ -166,16 +166,6 @@ void test_union(std::string const& caseid, G1 const& g1, G2 const& g2, ); } -#if defined(BOOST_GEOMETRY_USE_RESCALING) - // Without rescaling, point count might easily differ (which is no problem) - BOOST_CHECK_MESSAGE(expected_point_count < 0 || std::abs(int(n) - expected_point_count) < 3, - "union: " << caseid - << " #points expected: " << expected_point_count - << " detected: " << n - << " type: " << (type_for_assert_message()) - ); -#endif - BOOST_CHECK_MESSAGE(expected_area.contains(area, settings.percentage), "union: " << caseid << std::setprecision(20) << " #area expected: " << expected_area @@ -197,9 +187,6 @@ void test_union(std::string const& caseid, G1 const& g1, G2 const& g2, << string_from_type::name() << (ccw ? "_ccw" : "") << (open ? "_open" : "") -#if defined(BOOST_GEOMETRY_USE_RESCALING) - << "_rescaled" -#endif << ".svg"; std::ofstream svg(filename.str().c_str()); diff --git a/test/algorithms/set_operations/union/union.cpp b/test/algorithms/set_operations/union/union.cpp index 3e47a1287..3b23aaaa5 100644 --- a/test/algorithms/set_operations/union/union.cpp +++ b/test/algorithms/set_operations/union/union.cpp @@ -419,24 +419,17 @@ void test_areal() TEST_UNION(ticket_10108_a, count_set(1, 2), 0, 8, 0.0435229); TEST_UNION(ticket_10108_b, count_set(1, 2), 0, 10, 2424.3449); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // With rescaling, there is a dependency on cluster tolerance, which alters the result. TEST_UNION(ticket_10866, 1, 0, 14, 332760303.5); -#endif TEST_UNION(ticket_11725, 1, 1, 10, 7.5); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) - // With rescaling an extra overlapping polygon is generated, which is wrong TEST_UNION(issue_548, 1, 0, -1, 617382720000); -#endif TEST_UNION(issue_566_a, 1, 0, -1, 214.3728); TEST_UNION(issue_566_b, 1, 0, -1, 214.3728); TEST_UNION_REV(issue_566_a, 1, 0, -1, 214.3728); TEST_UNION_REV(issue_566_b, 1, 0, -1, 214.3728); -#if ! defined(BOOST_GEOMETRY_USE_RESCALING) || defined(BOOST_GEOMETRY_TEST_FAILURES) { // With rescaling, the input (was already an output of a previous step) // is somehow considered as invalid. Output is also invalid. @@ -445,7 +438,6 @@ void test_areal() settings.ignore_validity_on_invalid_input = false; TEST_UNION_WITH(issue_690, 2, 0, -1, 25492.0505); } -#endif TEST_UNION(issue_838, 1, 0, -1, expectation_limits(1.3333, 1.33785)); TEST_UNION_REV(issue_838, 1, 0, -1, expectation_limits(1.3333, 1.33785)); @@ -552,7 +544,7 @@ void test_areal() // Contains a self-intersection invalidity for ccw ut_settings settings; settings.set_test_validity(! is_ccw); - test_one("buffer_mp2", + test_one("buffer_mp2", buffer_mp2[0], buffer_mp2[1], 1, -1, 217, 36.752837, settings); } @@ -652,7 +644,7 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(4, 1, 2, 0); + BoostGeometryWriteExpectedFailures(1, 2, 0); #endif return 0; diff --git a/test/algorithms/set_operations/union/union_multi.cpp b/test/algorithms/set_operations/union/union_multi.cpp index cc2f9309a..906fed1c0 100644 --- a/test/algorithms/set_operations/union/union_multi.cpp +++ b/test/algorithms/set_operations/union/union_multi.cpp @@ -498,7 +498,7 @@ int test_main(int, char* []) #endif #if defined(BOOST_GEOMETRY_TEST_FAILURES) - BoostGeometryWriteExpectedFailures(9, 0, 1, 0); + BoostGeometryWriteExpectedFailures(0, 1, 0); #endif return 0; diff --git a/test/geometry_test_common.hpp b/test/geometry_test_common.hpp index 5eb7aa97f..e2b9cf461 100644 --- a/test/geometry_test_common.hpp +++ b/test/geometry_test_common.hpp @@ -185,11 +185,7 @@ inline T1 const& bg_if_mp(T1 const& value_mp, T2 const& value) } //! Macro for expectations depending on rescaling -#if defined(BOOST_GEOMETRY_USE_RESCALING) -#define BG_IF_RESCALED(a, b) a -#else #define BG_IF_RESCALED(a, b) b -#endif //! Macro for turning of a test setting when testing without failures #if defined(BOOST_GEOMETRY_TEST_FAILURES) @@ -207,14 +203,6 @@ inline void BoostGeometryWriteTestConfiguration() #if defined(BOOST_GEOMETRY_COMPILER_MODE_DEBUG) std::cout << " - Debug mode" << std::endl; #endif -#if defined(BOOST_GEOMETRY_ROBUSTNESS_ALTERNATIVE) - std::cout << " - Flipping the robustness alternative" << std::endl; -#endif -#if defined(BOOST_GEOMETRY_USE_RESCALING) - std::cout << " - Using rescaling" << std::endl; -#else - std::cout << " - No rescaling" << std::endl; -#endif #if defined(BOOST_GEOMETRY_TEST_ONLY_ONE_TYPE) std::cout << " - Testing only one type" << std::endl; #endif @@ -230,34 +218,28 @@ inline void BoostGeometryWriteTestConfiguration() #ifdef BOOST_GEOMETRY_TEST_FAILURES #define BG_NO_FAILURES 0 -inline void BoostGeometryWriteExpectedFailures(std::size_t for_rescaling, - std::size_t for_no_rescaling_double, - std::size_t for_no_rescaling_float, - std::size_t for_no_rescaling_extended) +inline void BoostGeometryWriteExpectedFailures(std::size_t for_double, + std::size_t for_float, + std::size_t for_extended) { - std::size_t const for_no_rescaling - = if_typed(for_no_rescaling_double, - if_typed(for_no_rescaling_float, - for_no_rescaling_extended)); + std::size_t const expected + = if_typed(for_double, + if_typed(for_float, + for_extended)); - boost::ignore_unused(for_rescaling, for_no_rescaling, for_no_rescaling_double, - for_no_rescaling_float, for_no_rescaling_extended); + boost::ignore_unused(expected, for_double, for_float, for_extended); -#if defined(BOOST_GEOMETRY_USE_RESCALING) - std::cout << "RESCALED - Expected: " << for_rescaling << " error(s)" << std::endl; -#elif defined(BOOST_GEOMETRY_TEST_ONLY_ONE_TYPE) && defined(BOOST_GEOMETRY_TEST_ONLY_ONE_ORDER) - std::cout << "NOT RESCALED - Expected: " << for_no_rescaling << " error(s)" << std::endl; +#if defined(BOOST_GEOMETRY_TEST_ONLY_ONE_TYPE) && defined(BOOST_GEOMETRY_TEST_ONLY_ONE_ORDER) + std::cout << "Expected: " << expected << " error(s)" << std::endl; #else std::cout << std::endl; #endif } -inline void BoostGeometryWriteExpectedFailures(std::size_t for_rescaling, - std::size_t for_no_rescaling_double = BG_NO_FAILURES) +inline void BoostGeometryWriteExpectedFailures(std::size_t for_double = BG_NO_FAILURES) { - BoostGeometryWriteExpectedFailures(for_rescaling, for_no_rescaling_double, - for_no_rescaling_double, for_no_rescaling_double); + BoostGeometryWriteExpectedFailures(for_double, for_double, for_double); } #endif diff --git a/test/robustness/overlay/areal_areal/test_overlay_p_q.hpp b/test/robustness/overlay/areal_areal/test_overlay_p_q.hpp index 2dc43c85d..5ed6cb5c4 100644 --- a/test/robustness/overlay/areal_areal/test_overlay_p_q.hpp +++ b/test/robustness/overlay/areal_areal/test_overlay_p_q.hpp @@ -260,11 +260,7 @@ static bool test_overlay_p_q(std::string const& caseid, { out << string_from_type::name(); } - out -#if defined(BOOST_GEOMETRY_USE_RESCALING) - << "_rescaled" -#endif - << "."; + out << "."; filename = out.str(); } diff --git a/test/robustness/overlay/buffer/recursive_polygons_buffer.cpp b/test/robustness/overlay/buffer/recursive_polygons_buffer.cpp index 847d19b3a..0369d5d61 100644 --- a/test/robustness/overlay/buffer/recursive_polygons_buffer.cpp +++ b/test/robustness/overlay/buffer/recursive_polygons_buffer.cpp @@ -136,9 +136,6 @@ bool verify(std::string const& caseid, MultiPolygon const& mp, MultiPolygon cons std::ostringstream out; out << "rec_pol_buffer_" << geometry_to_crc(mp) << "_" << string_from_type::type>::name() - #if defined(BOOST_GEOMETRY_USE_RESCALING) - << "_rescaled" - #endif << "."; filename = out.str(); }