Skip to content

Implement credential integration tests and enhanced deployment scripts#109

Merged
Josie123-Dev merged 1 commit into
GuardZero144:mainfrom
Smartdevs17:main
Jun 18, 2026
Merged

Implement credential integration tests and enhanced deployment scripts#109
Josie123-Dev merged 1 commit into
GuardZero144:mainfrom
Smartdevs17:main

Conversation

@Smartdevs17

Copy link
Copy Markdown
Contributor

Summary

This PR implements credential integration tests (Issue #99) and enhanced deployment scripts (Issue #97) for the ValidFi Soroban contracts.

Changes

Issue #99 - Credential Integration Tests

  • Contract integration tests (contracts/src/integration_tests.rs): 40 tests covering:
    • Identity lifecycle (register, update, revoke, verify)
    • Verification flow (submit, approve, reject)
    • Access control (grant, check, revoke, extend, expiry)
    • Data sharing (share, revoke, extend, expiry)
    • End-to-end credential lifecycle (patient -> doctor -> insurer)
    • Error scenarios (non-existent entities, unauthorized access)
  • Backend spec files for Identity, Verification, AccessControl, DataSharing, and Soroban services
  • Frontend integration tests for the credential-sharing component
  • All 63 contract tests pass with zero warnings

Issue #97 - Credential Deployment Scripts

  • Enhanced scripts/deploy-contracts.sh with:
    • Parameter validation (wallet address format, network name)
    • Network configuration system (testnet, mainnet, futurenet, local)
    • Deployment verification (post-deployment get_version queries)
    • Rollback capability with deployment state persistence
    • Automatic .env file updates
    • --status, --verify, --rollback CLI commands

Verification

  • cargo fmt
  • cargo clippy -- -D warnings
  • cargo test --features testutils (63/63 pass) ✓
  • cargo build --release --target wasm32-unknown-unknown

Closes #97
Closes #99

Closes GuardZero144#99 - Implement credential integration tests:
- Contract integration tests covering all four Soroban contracts
- Backend service spec files for identity, verification, access-control, data-sharing, and soroban services
- Frontend integration tests for credential-sharing component
- Test contract interactions (register->verify->grant->share)
- Test end-to-end credential lifecycle flow
- Test error scenarios (non-existent entities, unauthorized access)
- 40 new integration tests (63 total passing)

Closes GuardZero144#97 - Implement credential deployment scripts:
- Enhanced deploy-contracts.sh with proper parameter validation and wallet address format checking
- Network configuration system supporting testnet, mainnet, futurenet, local
- Deployment verification (post-deployment contract queries)
- Rollback capability with deployment state persistence
- Environment file auto-update
- Backup of previous deployment state for safe rollback
- Status and verify commands for deployment management
@vercel

vercel Bot commented Jun 18, 2026

Copy link
Copy Markdown

@Smartdevs17 is attempting to deploy a commit to the Josie's projects Team on Vercel.

A member of the Team first needs to authorize it.

@Josie123-Dev Josie123-Dev merged commit 467962c into GuardZero144:main Jun 18, 2026
1 of 2 checks passed
@Josie123-Dev

Copy link
Copy Markdown
Member

Thank you for your contribution @Smartdevs17

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.

[Hard] Implement credential integration tests [Hard] Implement credential deployment scripts

2 participants