diff options
author | Mike Kelly <mike.kelly@arm.com> | 2021-10-14 12:35:58 +0100 |
---|---|---|
committer | Mike Kelly <mike.kelly@arm.com> | 2021-10-14 12:35:58 +0100 |
commit | e2d611e4502fb5dce8b8a398ccfc8d7ef29da96b (patch) | |
tree | 79d9178420924d57ed0ab23db46ff57159279886 /test/1.2/Lstm.cpp | |
parent | 4bd8f7c96e01e081276c376fe5c34018e7b70d17 (diff) | |
download | android-nn-driver-e2d611e4502fb5dce8b8a398ccfc8d7ef29da96b.tar.gz |
IVGCVSW-6428 Remove asserts
* Changed asserts to check for errors and return appropriate values or
throw exceptions
* Changed unit tests to use Doctest's long macro names as the short
macro names clashed with Android's Logging macros
* Removed unused #includes
* Clarified ambiguous #includes
Signed-off-by: Mike Kelly <mike.kelly@arm.com>
Change-Id: Ice92a37590df727fd581d3be5ff2716665f26a13
Diffstat (limited to 'test/1.2/Lstm.cpp')
-rw-r--r-- | test/1.2/Lstm.cpp | 38 |
1 files changed, 25 insertions, 13 deletions
diff --git a/test/1.2/Lstm.cpp b/test/1.2/Lstm.cpp index 70fbf70f..59d5d381 100644 --- a/test/1.2/Lstm.cpp +++ b/test/1.2/Lstm.cpp @@ -1,5 +1,5 @@ // -// Copyright © 2017 Arm Ltd. All rights reserved. +// Copyright © 2017 Arm Ltd and Contributors. All rights reserved. // SPDX-License-Identifier: MIT // @@ -7,52 +7,64 @@ using namespace armnn_driver; -TEST_SUITE("LstmTests_1.2_CpuRef") +DOCTEST_TEST_SUITE("LstmTests_1.2_CpuRef") { - TEST_CASE("LstmNoCifgNoPeepholeNoProjectionTest_1.2_armnn::Compute::CpuRef") + + DOCTEST_TEST_CASE("LstmNoCifgNoPeepholeNoProjectionTest_1.2_armnn::Compute::CpuRef") { LstmNoCifgNoPeepholeNoProjection<hal_1_2::HalPolicy>(armnn::Compute::CpuRef); } - TEST_CASE("LstmCifgPeepholeNoProjectionTest_1.2_CpuRef") + + DOCTEST_TEST_CASE("LstmCifgPeepholeNoProjectionTest_1.2_CpuRef") { LstmCifgPeepholeNoProjection<hal_1_2::HalPolicy>(armnn::Compute::CpuRef); } - TEST_CASE("LstmNoCifgPeepholeProjectionTest_1.2_CpuRef") + + DOCTEST_TEST_CASE("LstmNoCifgPeepholeProjectionTest_1.2_CpuRef") { LstmNoCifgPeepholeProjection<hal_1_2::HalPolicy>(armnn::Compute::CpuRef); } - TEST_CASE("LstmCifgPeepholeNoProjectionBatch2Test_1.2_CpuRef") + + DOCTEST_TEST_CASE("LstmCifgPeepholeNoProjectionBatch2Test_1.2_CpuRef") { LstmCifgPeepholeNoProjectionBatch2<hal_1_2::HalPolicy>(armnn::Compute::CpuRef); } - TEST_CASE("QuantizedLstmTest_1.2_CpuRef") + + DOCTEST_TEST_CASE("QuantizedLstmTest_1.2_CpuRef") { QuantizedLstm<hal_1_2::HalPolicy>(armnn::Compute::CpuRef); } + } #if defined(ARMCOMPUTECL_ENABLED) -TEST_SUITE("LstmTests_1.2_GpuAcc") +DOCTEST_TEST_SUITE("LstmTests_1.2_GpuAcc") { - TEST_CASE("LstmNoCifgNoPeepholeNoProjectionTest_1.2_GpuAcc") + + DOCTEST_TEST_CASE("LstmNoCifgNoPeepholeNoProjectionTest_1.2_GpuAcc") { LstmNoCifgNoPeepholeNoProjection<hal_1_2::HalPolicy>(armnn::Compute::GpuAcc); } - TEST_CASE("LstmCifgPeepholeNoProjectionTest_1.2_GpuAcc") + + DOCTEST_TEST_CASE("LstmCifgPeepholeNoProjectionTest_1.2_GpuAcc") { LstmCifgPeepholeNoProjection<hal_1_2::HalPolicy>(armnn::Compute::GpuAcc); } - TEST_CASE("LstmNoCifgPeepholeProjectionTest_1.2_GpuAcc") + + DOCTEST_TEST_CASE("LstmNoCifgPeepholeProjectionTest_1.2_GpuAcc") { LstmNoCifgPeepholeProjection<hal_1_2::HalPolicy>(armnn::Compute::GpuAcc); } - TEST_CASE("LstmCifgPeepholeNoProjectionBatch2Test_1.2_GpuAcc") + + DOCTEST_TEST_CASE("LstmCifgPeepholeNoProjectionBatch2Test_1.2_GpuAcc") { LstmCifgPeepholeNoProjectionBatch2<hal_1_2::HalPolicy>(armnn::Compute::GpuAcc); } - TEST_CASE("QuantizedLstmTest_1.2_GpuAcc") + + DOCTEST_TEST_CASE("QuantizedLstmTest_1.2_GpuAcc") { QuantizedLstm<hal_1_2::HalPolicy>(armnn::Compute::GpuAcc); } + } #endif |