It's evening here in Nigeria and I am facing a problem while studying JUnit 5 Repeated tests:
@RepeatedTest(value=4, name= "{displayName} running: {currentRepetition}/{totalRepetitions}")
@DisplayName(”RepeatedTest”)
void repeatedTest() {
//removed for brevity.
}
In the above code, unlike the other placeholders, {displayName} isn't resolved. Why please?
CodePudding user response:
You forgot to put value in @DisplayName
annotation. Try this:
@RepeatedTest(value=4, name= "{displayName} running: {currentRepetition}/{totalRepetitions}")
@DisplayName("MyTestClass")
void repeatedTest() {
//removed for brevity.
}