From 804857176a54c56c8553b557e8d470ee8aef7005 Mon Sep 17 00:00:00 2001 From: Valerie Hau Date: Tue, 7 May 2019 11:45:06 -0700 Subject: [PATCH] Fix getDisplayCapabilitiesBasic VTS test Old test checked error code when calling getBrightnessSupport in the getDisplayCapabilitiesBasic test. However, it is possible that the function is not implemented (UNSUPPORTED). We want to return normally and use the returned supported boolean to check this instead. Bug: 132043561, 132056857 Test: VtsHalGraphicsComposerV2_3TargetTest Change-Id: I94f8f39ba9129c4a8d939a5385538db3489c46b9 --- graphics/composer/2.3/utils/vts/ComposerVts.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/graphics/composer/2.3/utils/vts/ComposerVts.cpp b/graphics/composer/2.3/utils/vts/ComposerVts.cpp index b7632097ab..d4f5b3a4de 100644 --- a/graphics/composer/2.3/utils/vts/ComposerVts.cpp +++ b/graphics/composer/2.3/utils/vts/ComposerVts.cpp @@ -192,10 +192,8 @@ Error ComposerClient::getDisplayCapabilities( bool ComposerClient::getDisplayBrightnessSupport(Display display) { bool support = false; - mClient->getDisplayBrightnessSupport(display, [&](const auto& error, const auto& tmpSupport) { - ASSERT_EQ(Error::NONE, error) << "failed to get brightness support"; - support = tmpSupport; - }); + mClient->getDisplayBrightnessSupport( + display, [&](const auto& /*error*/, const auto& tmpSupport) { support = tmpSupport; }); return support; }