| Modifier and Type | Class and Description |
|---|---|
| public static class | TestCaseTools.
This is a special version of TestSuite that fixes, once and for all, the irritating design of JUnit to invoke the constructor multiple times on a test class. |
| public static enum |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| private static String | |
| public static TestSuite | makeTestSuite(Class<T> cls)
Method to create a collection of nested TestSuites out of nested classes. |
| public static TestSuite | |
| private static String | |
| public static void |
| TestCaseTools | back to summary |
|---|---|
| public TestCaseTools() | |
| getSuffix | back to summary |
|---|---|
| private static String getSuffix(char ch, String str) | |
| makeTestSuite | back to summary |
|---|---|
| public static TestSuite makeTestSuite(Class<T> cls) Method to create a collection of nested TestSuites out of nested classes. Can either create standard JUnit TestSuites, or SingleInstanceTestSuites. | |
| makeTestSuite | back to summary |
|---|---|
| public static TestSuite makeTestSuite(Class<T> cls, TestCaseTools. | |
| makeTestSuiteName | back to summary |
|---|---|
| private static String makeTestSuiteName(Class<T> cls) | |
| reportTiming | back to summary |
|---|---|
| public static void reportTiming(int repCount, PrintStream out, List<TimedTest> timedTests) | |
construct an instance of the test class in inst
try {
for each test method
method.invoke( inst ) ;
} catch ... {
} finally {
invoke post method (if any)
}
| Modifier and Type | Class and Description |
|---|---|
| private class | TestCaseTools.
References Deprecated
A simple variant of JUnit's TestCase that invokes the
test method on the supplied test.
TestCase is deprecated or references (maybe indirectly) at least one deprecated element.
|
| Modifier and Type | Field and Description |
|---|---|
| private Method | |
| private Method | |
| private Method | |
| private Test |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| private Test | |
| private String | |
| private Method | |
| private boolean | |
| private boolean | |
| public void | run(TestResult result)
Overrides junit. Implements junit. Runs the tests and collects their result in a TestResult. |
| public void |
| postMethod | back to summary |
|---|---|
| private Method postMethod | |
| setUpMethod | back to summary |
|---|---|
| private Method setUpMethod | |
| tearDownMethod | back to summary |
|---|---|
| private Method tearDownMethod | |
| test | back to summary |
|---|---|
| private Test test | |
| SingleInstanceTestSuite | back to summary |
|---|---|
| public SingleInstanceTestSuite(final Class<T> theClass) | |
| addTestMethod | back to summary |
|---|---|
| private void addTestMethod(Method m, Vector<E> names, Test test) | |
| doWarning | back to summary |
|---|---|
| private Test doWarning(final String message) | |
| exceptionToString | back to summary |
|---|---|
| private String exceptionToString(Throwable t) | |
| getMethod | back to summary |
|---|---|
| private Method getMethod(Class<T> theClass, String name) | |
| isPublicTestMethod | back to summary |
|---|---|
| private boolean isPublicTestMethod(Method m) | |
| isTestMethod | back to summary |
|---|---|
| private boolean isTestMethod(Method m) | |
| run | back to summary |
|---|---|
| public void run(TestResult result) Overrides junit. Implements junit. Doc from junit. Runs the tests and collects their result in a TestResult. | |
| runTest | back to summary |
|---|---|
| public void runTest(Test test, TestResult result) Overrides junit. | |
References Deprecated
TestCase is deprecated or references (maybe indirectly) at least one deprecated element.
See corresponding docs for further information.
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected void | |
| protected void | setUp()
Overrides junit. Sets up the fixture, for example, open a network connection. |
| protected void | tearDown()
Overrides junit. Tears down the fixture, for example, close a network connection. |
| runMethod | back to summary |
|---|---|
| private Method runMethod | |
| SingleInstanceTestCase | back to summary |
|---|---|
| public SingleInstanceTestCase(Method runMethod) | |
| runTest | back to summary |
|---|---|
| protected void runTest() throws Throwable Overrides junit. Doc from junit. Override to run the test and assert its state.
| |
| setUp | back to summary |
|---|---|
| protected void setUp() Overrides junit. Doc from junit. Sets up the fixture, for example, open a network connection. This method is called before a test is executed. | |
| tearDown | back to summary |
|---|---|
| protected void tearDown() Overrides junit. Doc from junit. Tears down the fixture, for example, close a network connection. This method is called after a test is executed. | |
| Modifier and Type | Field and Description |
|---|---|
| public static final TestCaseTools. | |
| public static final TestCaseTools. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static TestCaseTools. | |
| public static TestCaseTools. |
| SINGLE | back to summary |
|---|---|
| public static final TestCaseTools. | |
| STANDARD | back to summary |
|---|---|
| public static final TestCaseTools. | |
| TestSuiteType | back to summary |
|---|---|
| private TestSuiteType() | |
| valueOf | back to summary |
|---|---|
| public static TestCaseTools. | |
| values | back to summary |
|---|---|
| public static TestCaseTools. | |