import junit.framework.Test; import junit.framework.TestCase; import junit.framework.TestSuite; /* This is an example of a TestSuite, the other component in the JUnit Test composite pattern */ public class BigTestSuite extends TestCase { public BigTestSuite(String name) { super(name); } public static Test suite() /* Assembles and returns a test suite containing all known tests. New tests should be added here! @return A non-null test suite. */ { TestSuite suite = new TestSuite(); // The ShoppingCartTest we created above. suite.addTest(EcomTestSuite.suite()); // add it a few more times just to fake a larger set of tests suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); suite.addTest(EcomTestSuite.suite()); // Another example test suite of tests. //suite.addTest(CreditCartTestSuite().suite()); return suite; } public static void main(String args[]) /* select which runner to use and fire off the test suite */ { String[] testCaseName = {BigTestSuite.class.getName()}; //junit.swingui.TestRunner.main(testCaseName); //junit.textui.TestRunner.main(testCaseName); junit.ui.TestRunner.main(testCaseName); } }