Class Then.Phase
java.lang.Object
io.axoniq.framework.workflow.runtime.test.fixture.Phase<Then.Phase>
io.axoniq.framework.workflow.runtime.test.fixture.Then<Then.Phase,GivenWhen.Phase>
io.axoniq.framework.workflow.runtime.test.fixture.Then.Phase
Default implementation of the
Then.-
Nested Class Summary
Nested classes/interfaces inherited from class io.axoniq.framework.workflow.runtime.test.fixture.Then
Then.Phase -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionWaits until any active workflow execution exists.executionExists(Predicate<WorkflowExecution> predicate) Waits until an active workflow execution matching the predicate exists.historyExists(WorkflowStatus workflowStatus) Waits until at least one workflow history exists and has the given status.historyExists(String workflowId) Waits until a workflow history exists for the given workflow id.historyExists(Predicate<WorkflowHistory> predicate) Waits until a workflow history matching the predicate exists.protected voidinitialize(WorkflowTestFixture<?, ?> fixture, WorkflowTestDriver testDriver) Initializes this phase with the owning fixture and the shared test driver.Asserts that no active workflow execution is present.Asserts that no workflow history is recorded.voidstop()Shuts down the test driver and all services.Methods inherited from class io.axoniq.framework.workflow.runtime.test.fixture.Then
and, hasSteps, hasStepsInAnyOrder, noStep, payloadContains, payloadEquals, payloadMatches, payloadSatisfies, step, stepsPassed, waitingIn, workflowFinished, workflowNotFinished, workflowStateSatisfies
-
Field Details
-
fixture
-
testDriver
-
-
Constructor Details
-
Phase
public Phase()
-
-
Method Details
-
initialize
Initializes this phase with the owning fixture and the shared test driver.The fixture calls this during construction so both phases operate on the same underlying workflow runtime and testing state.
- Parameters:
fixture- owning workflow test fixturetestDriver- shared workflow test driver
-
executionExists
Waits until any active workflow execution exists.- Returns:
- this phase for fluent chaining
-
executionExists
Waits until an active workflow execution matching the predicate exists.If exactly one execution matches, it becomes the selected execution for subsequent assertions.
- Parameters:
predicate- predicate used to select matching executions- Returns:
- this phase for fluent chaining
-
historyExists
Waits until a workflow history matching the predicate exists.If exactly one history matches, it becomes the selected history for subsequent assertions.
- Parameters:
predicate- predicate used to select matching histories- Returns:
- this phase for fluent chaining
-
historyExists
Waits until a workflow history exists for the given workflow id.- Parameters:
workflowId- workflow id to find- Returns:
- this phase for fluent chaining
-
historyExists
Waits until at least one workflow history exists and has the given status.- Parameters:
workflowStatus- expected workflow status- Returns:
- this phase for fluent chaining
-
noExecution
Asserts that no active workflow execution is present.- Returns:
- this phase for fluent chaining
-
noHistory
Asserts that no workflow history is recorded.- Returns:
- this phase for fluent chaining
-
stop
public void stop()Shuts down the test driver and all services.
-