Skip to content

[SC-39] Add code coverage reporting for the contracts workspace #1203

Description

@yusuftomilola

Overview

CI runs cargo test --all but never measures coverage — which is exactly how multisig_transfer reached 755 lines with zero tests unnoticed ([SC-32]).

Tasks

  • Add cargo-llvm-cov to CI and generate an lcov report.
  • Print a per-crate coverage summary so gaps are visible at a glance.
  • Set a workspace threshold at the current measured level so the build stays green, then ratchet upward.
  • Add a per-crate floor — this is what catches a zero-coverage crate that a workspace average would hide.
  • Optionally upload to Codecov and add a badge.

Acceptance Criteria

  • Coverage runs in CI with per-crate numbers.
  • A crate with no tests fails the per-crate floor.
  • Thresholds are committed and passing.

Dependencies

Pairs with [SC-32], [SC-40], [SC-41].

Notes for Contributors

Requires Rust + Soroban. Workspace: contracts/ (soroban-sdk 22, members: assetsup, contrib, multisig-wallet, multisig_transfer, asset-maintenance). Run cargo test --all, cargo fmt --all -- --check, and cargo clippy --all-targets --all-features -- -D warnings before opening a PR — CI enforces all three. Comment below to be assigned.

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programcontractdevopsCI/CD, infrastructure, and deploymenttestingTests, QA, and quality assurance

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions