AssertThat.Invoking Method
Overloads
| Name | Description |
|---|---|
| Invoking(Action) | Wraps an action for assertion testing. |
| Invoking<TResult>(Func<TResult>) | Wraps a function as an action for assertion testing, discarding the return value. |
Invoking(Action)
Wraps an action for assertion testing.
public static Action Invoking(Action action);
Parameters
| Name | Type | Description |
|---|---|---|
| action | Action | The action to test. |
Returns
The action, for use with Should(Action).
Invoking<TResult>(Func<TResult>)
Wraps a function as an action for assertion testing, discarding the return value.
public static Action Invoking<TResult>(Func<TResult> action);
Type Parameters
| Name | Description |
|---|---|
| TResult | The return type of the function. |
Parameters
| Name | Type | Description |
|---|---|---|
| action | Func<TResult> | The function to test. |
Returns
An action that invokes the function, for use with Should(Action).