Running JUnit 4 tests organised with inner classes [message #788050] |
Wed, 01 February 2012 04:38  |
Eclipse User |
|
|
|
Hi,
I have organised my JUnit tests using one test class for the class that I'm testing and one static inner class each for each method / behaviour that I'm testing.
public class TestMyClass {
public static class TestMyFirstMethod {
@Test
public void testMthodOneDoesSomething() {
// test code here
}
@Test
public void testMethodOneDoesSomethingElse() {
// test code here
}
}
public static class TestMyMethodTwo {
@Test
public void testMyMthodTwoDoesSomething() {
// test code here
}
}
}
This works really well for me from an organisational point of view, but I'm am having trouble finding out how to run all the scripts at once. When I shift+alt+X T to run the tests, Eclipse offers me a choice of all the inner classes to run and I seem to have to pick one rather than to run all of them at once.
I really want to run them all at the same time. Is there a way I can configure this?
Many thanks
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04907 seconds