Skip to content

[CONTRACT] Add regression tests for settlement state machine transitions #375

@dinahmaccodes

Description

@dinahmaccodes

Tier: Hard

Description: Extend settlement tests so the pending/completed/failed lifecycle stays locked to the actual token-transfer behavior.

Tasks:

  • Add a test that walks a settlement from pending to completed
  • Add a failure-path test that records an error code
  • Assert the active settlement link is cleared

Acceptance Criteria:

  • Pending settlements become completed exactly once
  • Failure stores an error code and clears active state
  • Settlement state updates are deterministic

Files: contracts/shipment/src/test_settlement_machine.rs, contracts/shipment/src/test_settlement.rs


Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions