From 48d97f3921320c78e055e104cb38b6be75722837 Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Mon, 31 Aug 2020 17:14:39 -0700 Subject: [PATCH] Mark GraphicsMapperHidlTest as allowing not being instantiated Only the variant(s) actually implemented by the device will be instantiated. This is consistent with tests for other versioned or optional HALs. Bug: b/167222309 Test: atest VtsHalGraphicsMapperV2_0TargetTest:GoogleTestVerification#UninstantiatedParameterizedTestSuite -- --abi arm64-v8a Change-Id: I4f1bfbad47bdbf75578ec48a3a56fb5351e7729a --- .../2.0/vts/functional/VtsHalGraphicsMapperV2_0TargetTest.cpp | 1 + .../2.1/vts/functional/VtsHalGraphicsMapperV2_1TargetTest.cpp | 3 ++- .../3.0/vts/functional/VtsHalGraphicsMapperV3_0TargetTest.cpp | 1 + .../4.0/vts/functional/VtsHalGraphicsMapperV4_0TargetTest.cpp | 1 + 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/graphics/mapper/2.0/vts/functional/VtsHalGraphicsMapperV2_0TargetTest.cpp b/graphics/mapper/2.0/vts/functional/VtsHalGraphicsMapperV2_0TargetTest.cpp index b079a4b689..7d733ff68e 100644 --- a/graphics/mapper/2.0/vts/functional/VtsHalGraphicsMapperV2_0TargetTest.cpp +++ b/graphics/mapper/2.0/vts/functional/VtsHalGraphicsMapperV2_0TargetTest.cpp @@ -410,6 +410,7 @@ TEST_P(GraphicsMapperHidlTest, UnlockNegative) { #endif } +GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST(GraphicsMapperHidlTest); INSTANTIATE_TEST_CASE_P( PerInstance, GraphicsMapperHidlTest, testing::Combine( diff --git a/graphics/mapper/2.1/vts/functional/VtsHalGraphicsMapperV2_1TargetTest.cpp b/graphics/mapper/2.1/vts/functional/VtsHalGraphicsMapperV2_1TargetTest.cpp index 3d792f9f8e..9f927e59f6 100644 --- a/graphics/mapper/2.1/vts/functional/VtsHalGraphicsMapperV2_1TargetTest.cpp +++ b/graphics/mapper/2.1/vts/functional/VtsHalGraphicsMapperV2_1TargetTest.cpp @@ -204,6 +204,7 @@ TEST_P(GraphicsMapperHidlTest, CreateDescriptor_2_1Negative) { }); } +GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST(GraphicsMapperHidlTest); INSTANTIATE_TEST_CASE_P( PerInstance, GraphicsMapperHidlTest, testing::Combine( @@ -218,4 +219,4 @@ INSTANTIATE_TEST_CASE_P( } // namespace mapper } // namespace graphics } // namespace hardware -} // namespace android \ No newline at end of file +} // namespace android diff --git a/graphics/mapper/3.0/vts/functional/VtsHalGraphicsMapperV3_0TargetTest.cpp b/graphics/mapper/3.0/vts/functional/VtsHalGraphicsMapperV3_0TargetTest.cpp index 92b5994eed..4187dd1354 100644 --- a/graphics/mapper/3.0/vts/functional/VtsHalGraphicsMapperV3_0TargetTest.cpp +++ b/graphics/mapper/3.0/vts/functional/VtsHalGraphicsMapperV3_0TargetTest.cpp @@ -458,6 +458,7 @@ TEST_P(GraphicsMapperHidlTest, IsSupportedY16) { ASSERT_NO_FATAL_FAILURE(supported = mGralloc->isSupported(info)); } +GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST(GraphicsMapperHidlTest); INSTANTIATE_TEST_CASE_P( PerInstance, GraphicsMapperHidlTest, testing::Combine( diff --git a/graphics/mapper/4.0/vts/functional/VtsHalGraphicsMapperV4_0TargetTest.cpp b/graphics/mapper/4.0/vts/functional/VtsHalGraphicsMapperV4_0TargetTest.cpp index bb775dc689..f55a6b77ed 100644 --- a/graphics/mapper/4.0/vts/functional/VtsHalGraphicsMapperV4_0TargetTest.cpp +++ b/graphics/mapper/4.0/vts/functional/VtsHalGraphicsMapperV4_0TargetTest.cpp @@ -2592,6 +2592,7 @@ TEST_P(GraphicsMapperHidlTest, GetReservedRegionBadBuffer) { ASSERT_EQ(0, reservedSize); } +GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST(GraphicsMapperHidlTest); INSTANTIATE_TEST_CASE_P( PerInstance, GraphicsMapperHidlTest, testing::Combine(