* Add state machine activity * address greptile state machine feedback * address state machine trigger cancellation feedback
799 B
799 B
Quickstart: State Machine Activity
- Add a
StateMachinewithInitialState = "NewOrder". - Add states named
NewOrderandPaid. - Add an entry activity to
NewOrder. - Add a transition from
NewOrdertoPaidwith a trigger activity and optional action. - Execute the workflow.
- Verify
NewOrderentry runs, outbound transition triggers are scheduled, and the workflow remains active. - Complete the trigger and verify
CurrentStatebecomesPaid. - Verify a false transition condition re-arms that transition trigger without canceling competing triggers.
- Verify entering a state with no valid outbound transitions completes the state machine.
Validation command:
dotnet test test/unit/Elsa.Activities.UnitTests/Elsa.Activities.UnitTests.csproj --no-restore