Fields or step parameters can be annotated with
Parameter
. Parameters are injected by tapir at Test execution
runtime. There are several ways how to provide the data:
- unparameterized @Parameter: You have to implement a method which's name is derived from the field / parameter name in
the test class which returns the parameter
value()
or method()
: You have to implement a method with the given name in the test class which returns
the parameter
providerClass()
: The given providerClass has to provide a method which returns the parameter. The method name
can be derived from the field / parameter name or explicitly specified by using value()
/method()
.
If a test class or step should be executed multiple times based on the parameter value, please consult
IteratedParameter
.