Skip TestGnssPowerIndication if capability is not supported am: 5da610c660 am: e0b0a8c2a7

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2397741

Change-Id: Ie26bcec33070bc82310231947497fee944e4e819
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Yu-Han Yang 2023-01-24 19:47:36 +00:00 committed by Automerger Merge Worker
commit f72b412a07

View file

@ -526,6 +526,11 @@ TEST_P(GnssHalTest, TestGnssPowerIndication) {
EXPECT_EQ(gnssPowerIndicationCallback->capabilities_cbq_.calledCount(), 1);
if (gnssPowerIndicationCallback->last_capabilities_ == 0) {
// Skipping the test since GnssPowerIndication is not supported.
return;
}
// Request and verify a GnssPowerStats is received
gnssPowerIndicationCallback->gnss_power_stats_cbq_.reset();
iGnssPowerIndication->requestGnssPowerStats();