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

Commit b9591926 authored by Yuyang Huang's avatar Yuyang Huang Committed by Gerrit Code Review
Browse files

Merge "Adapt CheckApfIsSupported for VSR-15 compatibility" into main

parents f3f6e5b2 641f0aed
Loading
Loading
Loading
Loading
+12 −8
Original line number Diff line number Diff line
@@ -171,14 +171,18 @@ TEST_P(WifiStaIfaceAidlTest, CheckApfIsSupported) {
        }
        StaApfPacketFilterCapabilities apf_caps = {};
        EXPECT_TRUE(wifi_sta_iface_->getApfPacketFilterCapabilities(&apf_caps).isOk());
    } else {
        return;
    }

    EXPECT_TRUE(isFeatureSupported(IWifiStaIface::FeatureSetMask::APF));
    StaApfPacketFilterCapabilities apf_caps = {};
    EXPECT_TRUE(wifi_sta_iface_->getApfPacketFilterCapabilities(&apf_caps).isOk());
        // The APF version must be 4 or higher and the usable memory must be at least
        // 1024 bytes.
    EXPECT_GE(apf_caps.version, 4);
    // Based on VSR-14 the usable memory must be at least 1024 bytes.
    EXPECT_GE(apf_caps.maxLength, 1024);
    if (vendor_api_level >= __ANDROID_API_V__) {
        // Based on VSR-15 the usable memory must be at least 2000 bytes.
        EXPECT_GE(apf_caps.maxLength, 2000);
    }
}