Remove non-CTS packets assertion code
Symptom:
testTrafficStatsForLocalhost fails when applications or services
except CTS are using network.
Root cause:
testTrafficStatsForLocalhost can't calculate the number of
non-localhost packets for CTS.
It includes the all of packets for applications/services except CTS
and non-localhost packets for CTS.
Solution:
Remove this assertion and only logging the number of packets.
Change-Id: I49243d59f359f3a543c6bdb46f6a2645cde8f292
diff --git a/tests/cts/net/src/android/net/cts/TrafficStatsTest.java b/tests/cts/net/src/android/net/cts/TrafficStatsTest.java
index a8dd8ac..930c742 100755
--- a/tests/cts/net/src/android/net/cts/TrafficStatsTest.java
+++ b/tests/cts/net/src/android/net/cts/TrafficStatsTest.java
@@ -214,8 +214,6 @@
long deltaRxOtherPackets = (totalRxPacketsAfter - totalRxPacketsBefore) - uidRxDeltaPackets;
if (deltaTxOtherPackets > 0 || deltaRxOtherPackets > 0) {
Log.i(LOG_TAG, "lingering traffic data: " + deltaTxOtherPackets + "/" + deltaRxOtherPackets);
- // Make sure that not too many non-localhost packets are accounted for
- assertTrue("too many non-localhost packets on the same UID", deltaTxOtherPackets + deltaRxOtherPackets < 20);
}
assertTrue("uidtxp: " + uidTxPacketsBefore + " -> " + uidTxPacketsAfter + " delta=" + uidTxDeltaPackets +