public class JUnit4TestAdapter extends Object implements Test, Filterable, Sortable, Describable
Constructor and Description |
---|
JUnit4TestAdapter(Class<?> newTestClass) |
JUnit4TestAdapter(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() |
Class<?> |
getTestClass() |
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 |
String |
toString() |
public JUnit4TestAdapter(Class<?> newTestClass)
public JUnit4TestAdapter(Class<?> newTestClass, JUnit4TestAdapterCache cache)
public int countTestCases()
Test
countTestCases
in interface Test
public void run(TestResult result)
Test
public Class<?> getTestClass()
public Description getDescription()
getDescription
in interface Describable
Description
showing the tests to be run by the receiverpublic void filter(Filter filter) throws NoTestsRemainException
Filterable
filter
.filter
in interface Filterable
filter
- the Filter
to applyNoTestsRemainException
- if all tests are filtered outCopyright © 2002–2021 JUnit. All rights reserved.