public class JUnit4TestAdapter extends java.lang.Object implements Test, Filterable, Sortable, Describable
Constructor and Description |
---|
JUnit4TestAdapter(java.lang.Class<?> newTestClass) |
JUnit4TestAdapter(java.lang.Class<?> newTestClass,
JUnit4TestAdapterCache cache) |
Modifier and Type | Method and Description |
---|---|
int |
countTestCases()
Counts the number of test cases that will be run by this test.
|
void |
filter(Filter filter)
Remove tests that don't pass the parameter
filter . |
Description |
getDescription() |
java.lang.Class<?> |
getTestClass() |
java.util.List<Test> |
getTests() |
void |
run(TestResult result)
Runs a test and collects its result in a TestResult instance.
|
void |
sort(Sorter sorter)
Sorts the tests using
sorter |
java.lang.String |
toString() |
public JUnit4TestAdapter(java.lang.Class<?> newTestClass)
public JUnit4TestAdapter(java.lang.Class<?> newTestClass, JUnit4TestAdapterCache cache)
public int countTestCases()
Test
countTestCases
in interface Test
public void run(TestResult result)
Test
public java.util.List<Test> getTests()
public java.lang.Class<?> getTestClass()
public Description getDescription()
getDescription
in interface Describable
Description
showing the tests to be run by the receiverpublic java.lang.String toString()
toString
in class java.lang.Object
public void filter(Filter filter) throws NoTestsRemainException
Filterable
filter
.filter
in interface Filterable
filter
- the Filter
to applyNoTestsRemainException
- if all tests are filtered out