Class StepPhrase
Maps a step operation (and optionally a required set of with-block keys) to a Gherkin keyword + phrase template.
public sealed record StepPhrase : IEquatable<StepPhrase>
- Inheritance
-
StepPhrase
- Implements
- Inherited Members
Constructors
StepPhrase(string, GherkinKeyword, string, IReadOnlyList<string>?)
Maps a step operation (and optionally a required set of with-block keys) to a Gherkin keyword + phrase template.
public StepPhrase(string StepOp, GherkinKeyword Keyword, string Template, IReadOnlyList<string>? RequiredKeys = null)
Parameters
StepOpstringStep name, e.g. "ui.click".
KeywordGherkinKeywordThe natural Gherkin keyword for this operation.
TemplatestringPhrase template. Placeholders are {key} where key matches a with-block key. Example: "I click {automationId}"
RequiredKeysIReadOnlyList<string>Optional set of keys that must be present in the with-block for this phrase to be selected. Used to distinguish overloads (e.g. testId variant of ui.click).
Properties
Keyword
The natural Gherkin keyword for this operation.
public GherkinKeyword Keyword { get; init; }
Property Value
RequiredKeys
Optional set of keys that must be present in the with-block for this phrase to be selected. Used to distinguish overloads (e.g. testId variant of ui.click).
public IReadOnlyList<string>? RequiredKeys { get; init; }
Property Value
StepOp
Step name, e.g. "ui.click".
public string StepOp { get; init; }
Property Value
Template
Phrase template. Placeholders are {key} where key matches a with-block key. Example: "I click {automationId}"
public string Template { get; init; }