expectCommand

fun expectCommand(body: Any, to: AggregateRef? = null): Command<*>

The handlers derived exactly one command, of body, to to when given, as expectCommands compares them: that command.


inline fun <reified C : Any> expectCommand(noinline check: C.() -> Unit = {}): C

The handlers derived exactly one command, a C, whose body check checks, as an aggregate's Expectations.expectEvent checks its event: that body.


fun <C : Any> expectCommand(type: KClass<C>, check: C.() -> Unit = {}): C

The handlers derived exactly one command, of type, whose body check checks: that body.