CountingTestResultListener
public
class
CountingTestResultListener
extends TestResultListener
java.lang.Object | ||
↳ | com.android.tradefed.result.TestResultListener | |
↳ | com.android.tradefed.result.CountingTestResultListener |
A TestResultListener
that tracks the total number of tests by TestStatus
Summary
Public constructors | |
---|---|
CountingTestResultListener()
|
Public methods | |
---|---|
int[]
|
getResultCounts()
Return the number of PASSED, INCOMPLETE, IGNORED etc tests. |
int
|
getTotalTests()
Return the total number of tests executed. |
boolean
|
hasFailedTests()
Helper method to determine if there any failing (one of Incomplete, AssumptionFailure, Failure) results. |
void
|
testResult(TestDescription test, TestResult result)
|
Public constructors
CountingTestResultListener
public CountingTestResultListener ()
Public methods
getResultCounts
public int[] getResultCounts ()
Return the number of PASSED, INCOMPLETE, IGNORED etc tests.
Returns | |
---|---|
int[] |
an array, indexed by TestStatus.ordinal(), that stores the number of tests with each status |
getTotalTests
public int getTotalTests ()
Return the total number of tests executed.
Returns | |
---|---|
int |
hasFailedTests
public boolean hasFailedTests ()
Helper method to determine if there any failing (one of Incomplete, AssumptionFailure, Failure) results.
Returns | |
---|---|
boolean |
testResult
public void testResult (TestDescription test, TestResult result)
Parameters | |
---|---|
test |
TestDescription |
result |
TestResult |