Quiz on Repeated Tests
Test what you’ve learned about repeated tests in JUnit 5.
1
When does the following test pass?
public class RepeatedTests {
int count = 0;
@RepeatedTest(3)
void repeat() {
count++;
assertEquals(1, count);
}
}
A)
The test always passes.
B)
It passes when using the default per_method
test class lifecycle.
C)
The test always fails.
Question 1 of 50 attempted
Get hands-on with 1400+ tech skills courses.