@Target(value={ANNOTATION_TYPE,METHOD}) @Retention(value=RUNTIME) @Documented @API(value=Experimental) @TestTemplate @ExtendWith(value=org.junit.jupiter.params.ParameterizedTestExtension.class) public @interface ParameterizedTest
@ParameterizedTest
is used to signal that the annotated method is a
parameterized test method.
@ParameterizedTest
methods must specify at least one
ArgumentsProvider
via the
@ArgumentsSource
or a corresponding composed annotation. The provider is responsible for
providing a Stream
of
Arguments
that will be used to
invoke the @ParameterizedTest
method. The method may have additional
parameters to be resolved by other
ParameterResolvers
at the end of the method's parameter list.
Method parameters may use
@ConvertWith
or a corresponding composed annotation to specify an explicit
ArgumentConverter
.
@ParameterizedTest
may also be used as a meta-annotation in order to
create a custom composed annotation that inherits the semantics
of @ParameterizedTest
.
@ParameterizedTest
methods must not be private
or static
.
ArgumentsSource
,
CsvFileSource
,
CsvSource
,
EnumSource
,
MethodSource
,
ValueSource
,
ConvertWith
public abstract String name
You may use the following placeholders:
{index}
: the current invocation index (1-based){arguments}
: the complete, comma-separated arguments list{0}
, {1}
, etc.: an individual argumentFor the latter, you may use MessageFormat
patterns
to customize formatting of values.
MessageFormat