In eclipse, with JUnit 4, you can right click a project or package and click Run as JUnit Test, and it will run all the JUnit tests within that grouping. Is there a way to d
JUnit provides the test Suite. Give that a try.
[...]
public class TestCaseA {
@Test
public void testA1() {
// omitted
}
}
[...]
public class TestCaseB {
@Test
public void testB1() {
// omitted
}
}
[...]
@RunWith(value=Suite.class)
@SuiteClasses(value = {TestCaseA.class})
public class TestSuiteA {
}
[...]
@RunWith(value=Suite.class)
@SuiteClasses(value = {TestCaseB.class})
public class TestSuiteB {
}
[...]
@RunWith(value = Suite.class )
@SuiteClasses(value = {TestSuiteA.class, TestSuiteB.class})
public class MasterTestSuite{
}