Class ScenarioOutlineChain<TExample, T>
- Namespace
- TinyBDD
- Assembly
- TinyBDD.dll
Represents a scenario outline chain with a current value type.
public sealed class ScenarioOutlineChain<TExample, T>
Type Parameters
TExampleThe type of example data.
TThe current value type in the chain.
- Inheritance
-
ScenarioOutlineChain<TExample, T>
- Inherited Members
Methods
And<TOut>(string, Func<T, TExample, TOut>)
Adds an And step that transforms the value using example data.
public ScenarioOutlineChain<TExample, TOut> And<TOut>(string title, Func<T, TExample, TOut> transform)
Parameters
titlestringThe step title.
transformFunc<T, TExample, TOut>A function that receives the current value and example data.
Returns
- ScenarioOutlineChain<TExample, TOut>
A new chain with the transformed type.
Type Parameters
TOutThe output type.
And<TOut>(string, Func<T, TOut>)
Adds an And step that transforms the value without using example data.
public ScenarioOutlineChain<TExample, TOut> And<TOut>(string title, Func<T, TOut> transform)
Parameters
Returns
- ScenarioOutlineChain<TExample, TOut>
A new chain with the transformed type.
Type Parameters
TOutThe output type.
Then(string, Func<T, bool>)
Adds a Then assertion without using example data.
public ScenarioOutlineTerminal<TExample, T> Then(string title, Func<T, bool> predicate)
Parameters
Returns
- ScenarioOutlineTerminal<TExample, T>
A terminal chain that can be executed with examples.
Then(string, Func<T, TExample, bool>)
Adds a Then assertion that uses example data.
public ScenarioOutlineTerminal<TExample, T> Then(string title, Func<T, TExample, bool> predicate)
Parameters
titlestringThe step title.
predicateFunc<T, TExample, bool>A predicate that receives the current value and example data.
Returns
- ScenarioOutlineTerminal<TExample, T>
A terminal chain that can be executed with examples.
When<TOut>(string, Func<T, TExample, TOut>)
Adds a When step that transforms the value using example data.
public ScenarioOutlineChain<TExample, TOut> When<TOut>(string title, Func<T, TExample, TOut> transform)
Parameters
titlestringThe step title.
transformFunc<T, TExample, TOut>A function that receives the current value and example data.
Returns
- ScenarioOutlineChain<TExample, TOut>
A new chain with the transformed type.
Type Parameters
TOutThe output type.
When<TOut>(string, Func<T, TOut>)
Adds a When step that transforms the value without using example data.
public ScenarioOutlineChain<TExample, TOut> When<TOut>(string title, Func<T, TOut> transform)
Parameters
Returns
- ScenarioOutlineChain<TExample, TOut>
A new chain with the transformed type.
Type Parameters
TOutThe output type.