Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 88126cde authored by Gabriel Biren's avatar Gabriel Biren
Browse files

Fix NAN-related VTS tests.

NAN is not supported by Cuttlefish, so check
for Aware support before running any related
tests.

Also fix the incorrect function call in
CreateP2pIface.

Bug: 263762326
Test: atest VtsHalWifiChipTargetTest
      (tested on Cuttlefish and Bluejay)
Change-Id: I3ec52fcc18aedad157dbc17d19078dde216261fb
parent 34081b36
Loading
Loading
Loading
Loading
+13 −1
Original line number Diff line number Diff line
@@ -583,6 +583,9 @@ TEST_P(WifiChipAidlTest, CreateApIface) {
 * CreateNanIface
 */
TEST_P(WifiChipAidlTest, CreateNanIface) {
    if (!::testing::deviceSupportsFeature("android.hardware.wifi.aware")) {
        GTEST_SKIP() << "Skipping this test since NAN is not supported.";
    }
    configureChipForNanAndGetIface();
}

@@ -590,7 +593,7 @@ TEST_P(WifiChipAidlTest, CreateNanIface) {
 * CreateP2pIface
 */
TEST_P(WifiChipAidlTest, CreateP2pIface) {
    configureChipForNanAndGetIface();
    configureChipForP2pAndGetIface();
}

/*
@@ -672,6 +675,9 @@ TEST_P(WifiChipAidlTest, GetApIfaceNames) {
 * GetNanIfaceNames
 */
TEST_P(WifiChipAidlTest, GetNanIfaceNames) {
    if (!::testing::deviceSupportsFeature("android.hardware.wifi.aware")) {
        GTEST_SKIP() << "Skipping this test since NAN is not supported.";
    }
    configureChipForConcurrencyType(IfaceConcurrencyType::NAN_IFACE);

    std::vector<std::string> iface_names;
@@ -753,6 +759,9 @@ TEST_P(WifiChipAidlTest, GetApIface) {
 * GetNanIface
 */
TEST_P(WifiChipAidlTest, GetNanIface) {
    if (!::testing::deviceSupportsFeature("android.hardware.wifi.aware")) {
        GTEST_SKIP() << "Skipping this test since NAN is not supported.";
    }
    std::shared_ptr<IWifiNanIface> iface = configureChipForNanAndGetIface();
    std::string iface_name = getNanIfaceName(iface);

@@ -822,6 +831,9 @@ TEST_P(WifiChipAidlTest, RemoveApIface) {
 * RemoveNanIface
 */
TEST_P(WifiChipAidlTest, RemoveNanIface) {
    if (!::testing::deviceSupportsFeature("android.hardware.wifi.aware")) {
        GTEST_SKIP() << "Skipping this test since NAN is not supported.";
    }
    std::shared_ptr<IWifiNanIface> iface = configureChipForNanAndGetIface();
    std::string iface_name = getNanIfaceName(iface);