Package-level declarations

Types

Link copied to clipboard
abstract class AggregateSpec<C : Any, S : Any>(block: AggregateDsl<S>.() -> Unit) : AbstractDynamicTestBuilder

Base class for writing aggregate specification tests using a domain-specific language (DSL).

Link copied to clipboard

Aggregate Verifier provides utilities for testing domain aggregates using the Given/When/Expect pattern.

Link copied to clipboard
class OrchestrationError(orchestrationStacks: Array<StackTraceElement>, cause: Throwable) : AssertionError

An exception that enhances test failure reporting by merging orchestration stack traces with execution stack traces.

Link copied to clipboard
abstract class SagaSpec<T : Any>(block: StatelessSagaDsl<T>.() -> Unit) : AbstractDynamicTestBuilder

Abstract base class for writing stateless saga specification tests using JUnit 5.

Link copied to clipboard

Utility object for creating and configuring stateless saga verifiers for testing.

Functions

Link copied to clipboard
inline fun <C : Any, S : Any> aggregateVerifier(aggregateId: String = generateGlobalId(), tenantId: String = TenantId.DEFAULT_TENANT_ID): GivenStage<S>

Creates a GivenStage for testing an aggregate using reified generic types.

inline fun <C : Any, S : Any> aggregateVerifier(aggregateId: String = generateGlobalId(), tenantId: String = TenantId.DEFAULT_TENANT_ID, serviceProvider: ServiceProvider): GivenStage<S>

Creates a GivenStage for testing an aggregate with custom service provider using reified generics.

inline fun <C : Any, S : Any> aggregateVerifier(aggregateId: String = generateGlobalId(), tenantId: String = TenantId.DEFAULT_TENANT_ID, eventStore: EventStore = InMemoryEventStore(), serviceProvider: ServiceProvider = SimpleServiceProvider()): GivenStage<S>

Creates a GivenStage for testing an aggregate with custom event store and service provider using reified generics.

Link copied to clipboard
fun <R> captureDynamicTest(displayName: String, block: () -> R): DynamicTest

Captures a dynamic test and wraps any AssertionError with OrchestrationError for improved stack traces.