Skip to content

test: add escrow security coverage #192 - #193

Open
belloaliyu11 wants to merge 1 commit into
Lumina-eX:mainfrom
belloaliyu11:fix-192-escrow-security-tests
Open

test: add escrow security coverage #192#193
belloaliyu11 wants to merge 1 commit into
Lumina-eX:mainfrom
belloaliyu11:fix-192-escrow-security-tests

Conversation

@belloaliyu11

Copy link
Copy Markdown

Overview

This PR expands the Soroban escrow contract test coverage around security-sensitive authorization paths, invalid milestone operations, repeated execution, and lifecycle event emission.

Related Issue

Closes #192

Changes

Escrow Security Tests

  • [MODIFY] contracts/contracts/escrow/src/test.rs
    • Adds reusable helpers for initializing and fully approving a single milestone.
    • Adds negative tests for unauthorized refund and dispute attempts.
    • Adds invalid milestone tests for submission and release paths.
    • Adds replay/double-execution tests for repeated release and refund attempts.
    • Adds post-completion transition tests to ensure disputes/refunds fail after release.
    • Adds event count validation across the successful escrow lifecycle.

CI Contract Test Coverage

  • [MODIFY] .github/workflows/ci.yml
    • Adds a contracts job that installs stable Rust and runs cargo test --workspace from the contracts workspace.

Verification Results

git diff --check
PASS

Local Rust verification could not be run in this Windows environment:

cargo fmt
FAILED: cargo is not installed or not available on PATH.

cargo test -p escrow
FAILED: cargo is not installed or not available on PATH.

The added CI job will run the Soroban contract test suite on GitHub Actions.

Acceptance Criteria Status
Critical authorization paths are tested Done
Invalid operations fail safely Done
Replay/double execution is rejected Done
Post-completion transitions are blocked Done
Contract tests are included in CI Done
Successful lifecycle event emission is validated Done

@drips-wave

drips-wave Bot commented Aug 25, 2026

Copy link
Copy Markdown

@belloaliyu11 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Escrow Security & Authorization Tests

1 participant