@API(value=Experimental) public interface RepetitionInfo
RepetitionInfo
is used to inject information about the current
repetition of a repeated test into @RepeatedTest
, @BeforeEach
,
and @AfterEach
methods.
If a method parameter is of type RepetitionInfo
, JUnit will
supply an instance of RepetitionInfo
corresponding to the current
repeated test as the value for the parameter.
RepeatedTest
,
TestInfo
Modifier and Type | Method and Description |
---|---|
int |
getCurrentRepetition()
Get the current repetition of the corresponding
@RepeatedTest method. |
int |
getTotalRepetitions()
Get the total number of repetitions of the corresponding
@RepeatedTest method. |
int getCurrentRepetition()
@RepeatedTest
method.int getTotalRepetitions()
@RepeatedTest
method.RepeatedTest.value()