diff options
Diffstat (limited to 'src/armnnUtils/test/ParserHelperTest.cpp')
-rw-r--r-- | src/armnnUtils/test/ParserHelperTest.cpp | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/src/armnnUtils/test/ParserHelperTest.cpp b/src/armnnUtils/test/ParserHelperTest.cpp index dbf0673bf5..2ed9bd1f03 100644 --- a/src/armnnUtils/test/ParserHelperTest.cpp +++ b/src/armnnUtils/test/ParserHelperTest.cpp @@ -8,15 +8,15 @@ #include <armnn/Tensor.hpp> #include <armnn/Types.hpp> -#include <boost/test/unit_test.hpp> +#include <doctest/doctest.h> using namespace armnn; using namespace armnnUtils; -BOOST_AUTO_TEST_SUITE(ParserHelperSuite) - -BOOST_AUTO_TEST_CASE(CalculateReducedOutputTensoInfoTest) +TEST_SUITE("ParserHelperSuite") +{ +TEST_CASE("CalculateReducedOutputTensoInfoTest") { bool keepDims = false; @@ -29,8 +29,8 @@ BOOST_AUTO_TEST_CASE(CalculateReducedOutputTensoInfoTest) CalculateReducedOutputTensoInfo(inputTensorInfo, axisData1, keepDims, outputTensorInfo1); - BOOST_TEST(outputTensorInfo1.GetNumDimensions() == 1); - BOOST_TEST(outputTensorInfo1.GetShape()[0] == 1); + CHECK(outputTensorInfo1.GetNumDimensions() == 1); + CHECK(outputTensorInfo1.GetShape()[0] == 1); // Reducing dimension 0 results in a 3x4 size tensor (one dimension) std::set<unsigned int> axisData2 = { 0 }; @@ -38,8 +38,8 @@ BOOST_AUTO_TEST_CASE(CalculateReducedOutputTensoInfoTest) CalculateReducedOutputTensoInfo(inputTensorInfo, axisData2, keepDims, outputTensorInfo2); - BOOST_TEST(outputTensorInfo2.GetNumDimensions() == 1); - BOOST_TEST(outputTensorInfo2.GetShape()[0] == 12); + CHECK(outputTensorInfo2.GetNumDimensions() == 1); + CHECK(outputTensorInfo2.GetShape()[0] == 12); // Reducing dimensions 0,1 results in a 4 size tensor (one dimension) std::set<unsigned int> axisData3 = { 0, 1 }; @@ -47,8 +47,8 @@ BOOST_AUTO_TEST_CASE(CalculateReducedOutputTensoInfoTest) CalculateReducedOutputTensoInfo(inputTensorInfo, axisData3, keepDims, outputTensorInfo3); - BOOST_TEST(outputTensorInfo3.GetNumDimensions() == 1); - BOOST_TEST(outputTensorInfo3.GetShape()[0] == 4); + CHECK(outputTensorInfo3.GetNumDimensions() == 1); + CHECK(outputTensorInfo3.GetShape()[0] == 4); // Reducing dimension 0 results in a { 1, 3, 4 } dimension tensor keepDims = true; @@ -58,10 +58,10 @@ BOOST_AUTO_TEST_CASE(CalculateReducedOutputTensoInfoTest) CalculateReducedOutputTensoInfo(inputTensorInfo, axisData4, keepDims, outputTensorInfo4); - BOOST_TEST(outputTensorInfo4.GetNumDimensions() == 3); - BOOST_TEST(outputTensorInfo4.GetShape()[0] == 1); - BOOST_TEST(outputTensorInfo4.GetShape()[1] == 3); - BOOST_TEST(outputTensorInfo4.GetShape()[2] == 4); + CHECK(outputTensorInfo4.GetNumDimensions() == 3); + CHECK(outputTensorInfo4.GetShape()[0] == 1); + CHECK(outputTensorInfo4.GetShape()[1] == 3); + CHECK(outputTensorInfo4.GetShape()[2] == 4); // Reducing dimension 1, 2 results in a { 2, 1, 1 } dimension tensor keepDims = true; @@ -71,12 +71,12 @@ BOOST_AUTO_TEST_CASE(CalculateReducedOutputTensoInfoTest) CalculateReducedOutputTensoInfo(inputTensorInfo, axisData5, keepDims, outputTensorInfo5); - BOOST_TEST(outputTensorInfo5.GetNumDimensions() == 3); - BOOST_TEST(outputTensorInfo5.GetShape()[0] == 2); - BOOST_TEST(outputTensorInfo5.GetShape()[1] == 1); - BOOST_TEST(outputTensorInfo5.GetShape()[2] == 1); + CHECK(outputTensorInfo5.GetNumDimensions() == 3); + CHECK(outputTensorInfo5.GetShape()[0] == 2); + CHECK(outputTensorInfo5.GetShape()[1] == 1); + CHECK(outputTensorInfo5.GetShape()[2] == 1); } -BOOST_AUTO_TEST_SUITE_END() +} |