givenAggregate
fun <S : Any> givenAggregate(model: AggregateModel<S>, id: String, vararg history: Any, tenantId: String = DEFAULT_TENANT, scope: Scope = Scope.NONE): GivenAggregate<S>
The aggregate id of model, in tenantId, at the state and version its history leaves it in, one commit per event, in scope: the aggregate whose next commit whenEvent of events hands over. The model replays the history, so the state is the one the aggregate's own sourcing builds; a peer's view state the processor reads without its model is built by hand with stateEvent.
fun <S : Any> givenAggregate(model: AggregateModel<S>, ref: AggregateRef, vararg history: Any, scope: Scope = Scope.NONE): GivenAggregate<S>
The aggregate ref of model at the state and version its history leaves it in, as givenAggregate does.