diff options
author | Mingguang Xu <mingguangxu@google.com> | 2019-10-25 17:28:55 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2019-10-25 17:28:55 +0000 |
commit | 5147e660f665977a7262696d2936ff5595e143d2 (patch) | |
tree | 9d6b6c3d79afaf5843c4a6ffbdad8a8d6cc46cdd /tests | |
parent | c67c01d936b541857223d55b6afccd8f976daa61 (diff) | |
parent | 0180596a8409d60ff2c216c94c1deaaa7e7930a0 (diff) |
Merge "Wifi usability: Clear the ring buffer after adding each usability stats to the upload list." into qt-qpr1-dev
Diffstat (limited to 'tests')
-rw-r--r-- | tests/wifitests/src/com/android/server/wifi/WifiMetricsTest.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/wifitests/src/com/android/server/wifi/WifiMetricsTest.java b/tests/wifitests/src/com/android/server/wifi/WifiMetricsTest.java index 7e086d4ce..73ac30f41 100644 --- a/tests/wifitests/src/com/android/server/wifi/WifiMetricsTest.java +++ b/tests/wifitests/src/com/android/server/wifi/WifiMetricsTest.java @@ -2999,9 +2999,10 @@ public class WifiMetricsTest { dumpProtoAndDeserialize(); assertEquals(2 * WifiMetrics.MAX_WIFI_USABILITY_STATS_PER_TYPE_TO_UPLOAD, mDecodedProto.wifiUsabilityStatsList.length); - for (int i = 0; i < mDecodedProto.wifiUsabilityStatsList.length; i++) { + for (int i = 0; i < WifiMetrics.MAX_WIFI_USABILITY_STATS_PER_TYPE_TO_UPLOAD; i++) { assertEquals(WifiMetrics.MAX_WIFI_USABILITY_STATS_ENTRIES_LIST_SIZE, - mDecodedProto.wifiUsabilityStatsList[i].stats.length); + mDecodedProto.wifiUsabilityStatsList[2 * i].stats.length); + assertEquals(2, mDecodedProto.wifiUsabilityStatsList[2 * i + 1].stats.length); } } |