From 984b6e0607a8e4e2dbfbc11e6a8666ce16491c67 Mon Sep 17 00:00:00 2001 From: Roshan Pius Date: Wed, 23 Sep 2020 15:19:30 -0700 Subject: [PATCH] supplicant(vts): Stop adding empty instance for vendor HAL We don't need to test supplicant in the presence of vendor HAL & without it. For a given device, this behavior is fixed. Bug: 161951052 Test: atest VtsHalWifiSupplicantV1_1TargetTest Change-Id: I71097c3afef1765ca514abf2c350c423e3999020 --- .../1.1/vts/functional/supplicant_hidl_test.cpp | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/wifi/supplicant/1.1/vts/functional/supplicant_hidl_test.cpp b/wifi/supplicant/1.1/vts/functional/supplicant_hidl_test.cpp index 4d952e4760..0b56957d31 100644 --- a/wifi/supplicant/1.1/vts/functional/supplicant_hidl_test.cpp +++ b/wifi/supplicant/1.1/vts/functional/supplicant_hidl_test.cpp @@ -33,6 +33,7 @@ using ::android::hardware::wifi::supplicant::V1_0::SupplicantStatus; using ::android::hardware::wifi::supplicant::V1_0::SupplicantStatusCode; using ::android::hardware::wifi::supplicant::V1_0::IfaceType; using ::android::hardware::wifi::supplicant::V1_1::ISupplicant; +using ::android::hardware::wifi::V1_0::IWifi; using ::android::sp; class SupplicantHidlTest : public SupplicantHidlTestBaseV1_1 { @@ -139,20 +140,11 @@ TEST_P(SupplicantHidlTest, RemoveP2pInterface) { */ TEST_P(SupplicantHidlTest, Terminate) { supplicant_->terminate(); } -static std::vector get_wifi_instances() { - std::vector instances = - android::hardware::getAllHalInstanceNames( - android::hardware::wifi::V1_0::IWifi::descriptor); - // Also test when wifi instance is not set. - instances.push_back(""); - - return instances; -} - INSTANTIATE_TEST_CASE_P( PerInstance, SupplicantHidlTest, testing::Combine( - testing::ValuesIn(get_wifi_instances()), + testing::ValuesIn( + android::hardware::getAllHalInstanceNames(IWifi::descriptor)), testing::ValuesIn(android::hardware::getAllHalInstanceNames( android::hardware::wifi::supplicant::V1_1::ISupplicant:: descriptor))),