Annotations
tip
Use annotations in meta and avoid them in features where possible.
Annotation | Level(s) | Since | Description |
---|---|---|---|
@StepDef | Scenario | v1.0.0 | Turns a Gherkin Scenario into a callable step definition |
@Import | Feature Meta | v1.9.0 | Loads specific meta files into a feature (or another meta) without relying on automatic discovery or other mechanisms |
@Synchronized | StepDef | v2.26.0 | Ensures that only one thread can call a StepDef at any one time during parallel execution |
@Synchronised | StepDef | v2.26.0 | Same as a @Synchronized above but with AU spelling instead |
@DataTable | StepDef | v2.47.0 | Associates a step definition with a Gherkin data table |
@ForEach | StepDef | v2.47.0 | Iterates over the records of a Gherkin data table |
@Examples | Scenario Outline | v2.4.0 | Imports data from a CSV file into an examples table in a Scenario Outline |
@Context | StepDef | v2.41.0 | Assigns context behavior to a step definition so it can only be called by Given steps |
@Action | StepDef | v2.41.0 | Assigns action behavior to a step definition so it can only be called by When steps |
@Assertion | StepDef | v2.41.0 | Assigns assertion behavior to a step definition so it can only be called by Then steps |
@Message | Step | v3.31.12 | Overrides the default error message for a failed assertion with a custom one |
@Try | Step | v3.11.0 | Instructs Gwen to ignore a failed step and continue procesing |
@Finally | Step | v3.3.0 | Forces the last step in a Scenario to always execute even when prior ones fail or are skipped |
@Eager | Step | v3.9.0 | Immediately evaluates and assigns values to refereces in place instead of at each call site |
@Lazy | Step | v3.9.0 | Evaluates and assigns values to refereces when they are first used at a call site only |
@Breakpoint | Step | v3.2.0 | Pauses execution on a step when Gwen is launched in debug mode |
@Hard | Step | v3.43.0 | Reports an assertion error occurring in a step, raises it as a failure and skips further processing |
@Soft | Step | v3.43.0 | Reports an assertion error occurring in a step, raises it as failure and continues processing |
@Sustained | Step | v3.43.0 | Reports an assertion error occurring in a step without raising it as a failure and continues processing |
@DryRun | Step | v3.55.0 | Forces references to take on certain given values when evaluated in dry runs |
@Masked | Step | v3.67.0 | Masks (hides) the value returned by a data binding |
@Parallel | Examples | v3.69.0 | Executes expanded examples in outlines in parallel |
@Timeout | Step | v3.73.0 | Specifies a timeout period on a wait, until/while, for each, assertion or locator DSL step. Examples: @Timeout('10s') , @Timeout('2m30s') , @Timeout('2m') |
@Delay | Step | v3.73.0 | Specifies a delay interval on a wait, until/while DSL step. Examples: @Delay('2s') , @Delay('1s500ms') , @Delay('1m') |
@Results | Feature Rule Scenario StepDef Scenario Outline Examples | v3.77.0 | Generates CSV results for a gherkin node |
@Trim | Step | v3.62.0 | Trims strings when performing comparison operations |
@IgnoreCase | Step | v3.62.0 | Ignores case when performing comparison operations |
@Ignore | Feature Scenario Rule Background Examples | v1.0.0 | Ignores and skips over a Gherkin block/node to avoid evaluation |