// Copyright © Advanced Micro Devices, Inc., or its affiliates. // SPDX-License-Identifier: MIT #include #include #include #include using namespace hipdnn_gpu_ref; // ============================================================================ // TestGpuRefHipError — throwOnHipError coverage // ============================================================================ TEST(TestGpuRefHipError, ThrowsOnError) { EXPECT_THROW(detail::throwOnHipError(hipErrorMemoryAllocation, "test"), std::runtime_error); } TEST(TestGpuRefHipError, NoThrowOnSuccess) { EXPECT_NO_THROW(detail::throwOnHipError(hipSuccess, "test")); }