You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@ExtendWith(ConditionalOrderingExtension.class)
@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
@Grade
public class ConditionalOrderedTest {
@Test
@Order(1)
public void test1() {
}
@Test
@Order(2)
public void test2() {
fail();
}
@ParameterizedTest
@ValueSource(ints = {1, 2, 3})
@Order(3)
public void test3(int a) {
}
}
Gives a grade of 0.33/1, because 3 tests are evaluated (failure of test2 makes the rest of the tests fails). However, without using the extension, a grade of 0.2/1 would be retrieved instead because 3 tests cases are actually run in test3.
Solution
Make the ConditionalOrderingExtension still evaluate the number of parametrized tests to run
The text was updated successfully, but these errors were encountered:
Problem
The following test class
Gives a grade of 0.33/1, because 3 tests are evaluated (failure of
test2
makes the rest of the tests fails). However, without using the extension, a grade of 0.2/1 would be retrieved instead because 3 tests cases are actually run intest3
.Solution
Make the
ConditionalOrderingExtension
still evaluate the number of parametrized tests to runThe text was updated successfully, but these errors were encountered: