diff --git a/qa/shape_poly_set_refactor/CMakeLists.txt b/qa/shape_poly_set_refactor/CMakeLists.txt index 3100328b55..d6b72aeb0b 100644 --- a/qa/shape_poly_set_refactor/CMakeLists.txt +++ b/qa/shape_poly_set_refactor/CMakeLists.txt @@ -28,7 +28,7 @@ add_definitions(-DBOOST_TEST_DYN_LINK) add_executable( qa_shape_poly_set_refactor test_module.cpp - test_chamfer_fillet.cpp + test_chamfer.cpp test_collision.cpp test_iterator.cpp test_segment.cpp @@ -56,5 +56,5 @@ target_link_libraries( qa_shape_poly_set_refactor add_dependencies( qa_shape_poly_set_refactor pcbnew ) add_test( NAME shape_poly_set_refactor - COMMAND qa_shape_poly_set_refactor --run_test=!ChamferFillet/Fillet + COMMAND qa_shape_poly_set_refactor ) diff --git a/qa/shape_poly_set_refactor/test_chamfer_fillet.cpp b/qa/shape_poly_set_refactor/test_chamfer.cpp similarity index 78% rename from qa/shape_poly_set_refactor/test_chamfer_fillet.cpp rename to qa/shape_poly_set_refactor/test_chamfer.cpp index 8d5c9f4754..22dc245c4e 100644 --- a/qa/shape_poly_set_refactor/test_chamfer_fillet.cpp +++ b/qa/shape_poly_set_refactor/test_chamfer.cpp @@ -34,7 +34,7 @@ /** * Declares the ChamferFilletFixture struct as the boost test fixture. */ -BOOST_FIXTURE_TEST_SUITE( ChamferFillet, ChamferFilletFixture ) +BOOST_FIXTURE_TEST_SUITE( Chamfer, ChamferFilletFixture ) /** * Function lexicographicOrder @@ -120,40 +120,4 @@ BOOST_AUTO_TEST_CASE( Chamfer ) } } -/** - * Tests the SHAPE_POLY_SET::FilletPolygon, which has been refactored into - * SHAPE_POLY_SET from CPolyLine::Fillet. - * Assuming the code in CPolyLine is right, this test ensures the behaviour of the new - * refactored code does not change anything. - */ -BOOST_AUTO_TEST_CASE( Fillet ) -{ - SHAPE_POLY_SET::POLYGON actual; - CPolyLine expected; - - // Test different radius, up to the half of the minimum segment longitude - for (int radius = 1; radius < 5; radius++) - { - // Test different number of segments - for (size_t segments = 1; segments < 100; segments++) - { - // Chamfered polygon to be tested. - actual = common.holeyPolySet.FilletPolygon( radius, segments, 0 ); - - // Chamfered polygon assumed to be right. - expected = *legacyPolyLine.Fillet( radius, segments ); - - // Double check that there are no repeated corners in the legacy shape. - expected.RemoveNullSegments(); - - // Test equality - for (size_t contourIdx = 0; contourIdx < actual.size(); contourIdx++) - { - TestLineChainEqualCPolyLine(actual[contourIdx], expected, contourIdx); - } - } - } -} - - BOOST_AUTO_TEST_SUITE_END()