| Clean Architecture Toolkit for .NET | |||||
|
Clean Architecture Toolkit is a clean, modular architecture foundation for .NET applications. It embraces SOLID principles and focuses on maintainability, testability, and scalability through clear boundaries and pluggable design. |
|
||||
|
| HOME | REPO OVERVIEW | DEMO | CAT.UNITTESTING | |
|||||
>> Cat.UnitTesting.Commands Assembly >> Cat.UnitTesting.Commands Namespace >> FakeCommandProcessor Class
| Overloads | |
|---|---|
| Respond<TCommand,TResult>(ICatResponse<TResult>) | Sets the response for a command with a result. |
| Respond<TCommand,TResult>(Func<TCommand,ICatResponse<TResult>>) | Sets the response for a command with a result, built from the command. |
| Respond<TCommand>(ICatResponse) | Sets the response for a command without a result. |
| Respond<TCommand>(Func<TCommand,ICatResponse>) | Sets the response for a command without a result, built from the command. |
Sets the response for a command with a result.
public Cat.UnitTesting.Commands.FakeCommandProcessor Respond<TCommand,TResult>(Cat.Responses.Abstractions.ICatResponse<TResult> response)
where TCommand : Cat.Commands.Abstractions.ICatCommand<TResult>;TCommand
The command type.
TResult
The type of the result.
response Cat.Responses.Abstractions.ICatResponse<TResult>
The response every command of this type gets.
FakeCommandProcessor
The fake, so calls can be chained.
Sets the response for a command with a result, built from the command.
public Cat.UnitTesting.Commands.FakeCommandProcessor Respond<TCommand,TResult>(System.Func<TCommand,Cat.Responses.Abstractions.ICatResponse<TResult>> respond)
where TCommand : Cat.Commands.Abstractions.ICatCommand<TResult>;TCommand
The command type.
TResult
The type of the result.
respond System.Func<TCommand,Cat.Responses.Abstractions.ICatResponse<TResult>>
Builds the response from the command.
FakeCommandProcessor
The fake, so calls can be chained.
Sets the response for a command without a result.
public Cat.UnitTesting.Commands.FakeCommandProcessor Respond<TCommand>(Cat.Responses.Abstractions.ICatResponse response)
where TCommand : Cat.Commands.Abstractions.ICatCommand;TCommand
The command type.
response ICatResponse
The response every command of this type gets.
FakeCommandProcessor
The fake, so calls can be chained.
Sets the response for a command without a result, built from the command.
public Cat.UnitTesting.Commands.FakeCommandProcessor Respond<TCommand>(System.Func<TCommand,Cat.Responses.Abstractions.ICatResponse> respond)
where TCommand : Cat.Commands.Abstractions.ICatCommand;TCommand
The command type.
respond System.Func<TCommand,ICatResponse>
Builds the response. It can also change the command, as a real handler would.
FakeCommandProcessor
The fake, so calls can be chained.