|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.evanmclean.evlib.junit.TestAll
public final class TestAll
Generates a test suite for the entire Java implementation. Runs all Java test cases in the source tree that extend TestCase and are of a specified type.
A typical implementation of a test suite class that uses this object is:
public class AllTests { public static Test suite() throws Throwable { return TestAll.getSuite("target/test-classes", "com.company.app.sub1", "UNIT"); } }
See getSuite(String, String, String)
for more details.
Field Summary | |
---|---|
static String |
DEFAULT_TEST_TYPE
The default test type value for test_type , which is
"UNIT". |
Method Summary | |
---|---|
static junit.framework.Test |
getSuite(String class_root,
String package_root)
Dynamically create a test suite from a set of class files in a directory tree, using the default test_type of "UNIT". |
static junit.framework.Test |
getSuite(String class_root,
String package_root,
String test_type)
Dynamically create a test suite from a set of class files in a directory tree. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String DEFAULT_TEST_TYPE
test_type
, which is
"UNIT".
Method Detail |
---|
public static junit.framework.Test getSuite(String class_root, String package_root) throws Throwable
test_type
of "UNIT".
class_root
- The directory containing the classes. e.g.,
/product/classes
package_root
- Where to start looking for packages within the package tree. e.g.,
com.company.app.sub1
will only run tests in package
com.company.app.sub1
or below.
Throwable
public static junit.framework.Test getSuite(String class_root, String package_root, String test_type) throws Throwable
class_root
- The directory containing the classes. e.g.,
/product/classes
package_root
- Where to start looking for packages within the package tree. e.g.,
com.company.app.sub1
will only run tests in package
com.company.app.sub1
or below.test_type
- Tye type of test case to load. All test cases with
public static
final String TEST_ALL_TEST_TYPE
defined to match the value of
test_type
will be loaded. The default value (specified
by DEFAULT_TEST_TYPE
) is "UNIT".
Throwable
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |