commit | 6bfe9da357aa254b374d801ce555096d8737df1c | [log] [tgz] |
---|---|---|
author | Frank <lifr@google.com> | Tue May 24 10:53:43 2022 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Tue May 24 10:53:43 2022 +0000 |
tree | e0a9410bc8decc28e0a9af46900464cc1543ead1 | |
parent | f2d3148059b9ad3abe0d8537dff3890160b90d5e [diff] | |
parent | a632356e051270a6e6080238e2f319e5f6a709ae [diff] |
Fix incorrect sdk version check in SCV2 device test am: a632356e05 Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/2103110 Change-Id: I2b4a82032dd85f7c70d7e559335c8d4fed6e238d Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/Tethering/tests/unit/src/com/android/networkstack/tethering/OffloadControllerTest.java b/Tethering/tests/unit/src/com/android/networkstack/tethering/OffloadControllerTest.java index e9716b3..8ef0c76 100644 --- a/Tethering/tests/unit/src/com/android/networkstack/tethering/OffloadControllerTest.java +++ b/Tethering/tests/unit/src/com/android/networkstack/tethering/OffloadControllerTest.java
@@ -26,6 +26,7 @@ import static android.net.RouteInfo.RTN_UNICAST; import static android.provider.Settings.Global.TETHER_OFFLOAD_DISABLED; +import static com.android.modules.utils.build.SdkLevel.isAtLeastS; import static com.android.modules.utils.build.SdkLevel.isAtLeastT; import static com.android.networkstack.tethering.OffloadController.StatsType.STATS_PER_IFACE; import static com.android.networkstack.tethering.OffloadController.StatsType.STATS_PER_UID; @@ -668,7 +669,7 @@ if (isAtLeastT()) { mTetherStatsProviderCb.expectNotifyLimitReached(); - } else if (Build.VERSION.SDK_INT == Build.VERSION_CODES.S) { + } else if (isAtLeastS()) { mTetherStatsProviderCb.expectNotifyWarningOrLimitReached(); } else { mTetherStatsProviderCb.expectNotifyLimitReached();