Open
Description
With ConditionalOrderedTest
, the failure of test2a
will prevent the execution of test2b
. Another extension could only skip one level whenever a test from the previous level has failed. This would still allow test2b
to run.
@ExtendWith(ConditionalOrderingExtension.class)
@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
@Grade
public class ConditionalOrderedTest {
@Test
@Order(1)
public void test1() {
System.out.println(1);
}
@Test
@Order(2)
public void test2a() {
fail();
}
@Test
@Order(2)
public void test2b() {
}
@Test
@Order(3)
public void test3() {
System.out.println(3);
}
}