Package-level declarations
Types
Link copied to clipboard
Defines the interface for aggregate expectation testing in the WOW framework.
Link copied to clipboard
class EventIterator(val delegate: Iterator<DomainEvent<*>>) : Iterator<DomainEvent<*>> , Decorator<Iterator<DomainEvent<*>>>
A decorator for iterating over domain events with convenient access methods.
Link copied to clipboard
data class ExpectedResult<S : Any>(val exchange: ServerCommandExchange<*>, val stateAggregate: StateAggregate<S>, val domainEventStream: DomainEventStream? = null, val error: Throwable? = null)
Encapsulates the complete result of an aggregate command execution for testing purposes.
Link copied to clipboard
Defines the stage for specifying expectations after command execution in aggregate testing.
Link copied to clipboard
object GivenInitialization
Marker object representing an initialization command for testing purposes.
Link copied to clipboard
data class GivenInitializationCommand(val aggregateId: AggregateId, val id: String = generateGlobalId(), val ownerId: String = OwnerId.DEFAULT_OWNER_ID, val requestId: String = generateGlobalId(), val isCreate: Boolean = true, val allowCreate: Boolean = false, val isVoid: Boolean = false, val header: Header = DefaultHeader.empty()) : CommandMessage<GivenInitialization> , NamedAggregate
A command message used for initializing aggregates with given events during testing.
Link copied to clipboard
Defines the stage for setting up test preconditions in aggregate testing.
Link copied to clipboard
Defines the stage after command execution and expectation verification in aggregate testing.
Functions
Link copied to clipboard
fun <S : Any> GivenStage<S>.whenCommand(command: Any, header: Header = DefaultHeader.empty(), ownerId: String = OwnerId.DEFAULT_OWNER_ID): ExpectStage<S>
Extension function that allows executing a command directly from the Given stage.