[RTT][CTS] Add information to assert to help debug failures
Modify the assert message to print out the # of failures and the total number of iterations. Will help diagnose scope of test failures. Bug: 109836816 Test: atest WifiRttTest Change-Id: Ic4d5b6844225edbd9704694c539e31754b7a340c
This commit is contained in:
@@ -157,7 +157,8 @@ public class WifiRttTest extends TestBase {
|
||||
reportLog.submit();
|
||||
|
||||
// Analyze results
|
||||
assertTrue("Wi-Fi RTT failure rate exceeds threshold",
|
||||
assertTrue("Wi-Fi RTT failure rate exceeds threshold: FAIL=" + numFailures + ", ITERATIONS="
|
||||
+ NUM_OF_RTT_ITERATIONS,
|
||||
numFailures <= NUM_OF_RTT_ITERATIONS * MAX_FAILURE_RATE_PERCENT / 100);
|
||||
if (numFailures != NUM_OF_RTT_ITERATIONS) {
|
||||
double distanceAvg = distanceSum / (NUM_OF_RTT_ITERATIONS - numFailures);
|
||||
|
||||
Reference in New Issue
Block a user