Package org.junit.runner
Class Result
- java.lang.Object
-
- org.junit.runner.Result
-
- All Implemented Interfaces:
java.io.Serializable
public class Result extends java.lang.Object implements java.io.Serializable
AResult
collects and summarizes information from running multiple tests. All tests are counted -- additional information is collected from tests that fail.- Since:
- 4.0
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Result()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RunListener
createListener()
Internal use only.int
getAssumptionFailureCount()
Returns the number of tests skipped because of an assumption failureint
getFailureCount()
Returns the number of tests that failed during the runjava.util.List<Failure>
getFailures()
Returns theFailure
s describing tests that failed and the problems they encounteredint
getIgnoreCount()
int
getRunCount()
Returns the number of tests runlong
getRunTime()
Returns the number of milliseconds it took to run the entire suite to runboolean
wasSuccessful()
-
-
-
Constructor Detail
-
Result
public Result()
-
-
Method Detail
-
getRunCount
public int getRunCount()
Returns the number of tests run
-
getFailureCount
public int getFailureCount()
Returns the number of tests that failed during the run
-
getRunTime
public long getRunTime()
Returns the number of milliseconds it took to run the entire suite to run
-
getFailures
public java.util.List<Failure> getFailures()
Returns theFailure
s describing tests that failed and the problems they encountered
-
getIgnoreCount
public int getIgnoreCount()
- Returns:
- the number of tests ignored during the run
-
getAssumptionFailureCount
public int getAssumptionFailureCount()
Returns the number of tests skipped because of an assumption failure- Throws:
java.lang.UnsupportedOperationException
- if the result was serialized in a version before JUnit 4.13- Since:
- 4.13
-
wasSuccessful
public boolean wasSuccessful()
- Returns:
true
if all tests succeeded
-
createListener
public RunListener createListener()
Internal use only.
-
-