Skip to content

Solidity Coverage job: test behaves differently under forge coverage --ir-minimum #6

Description

@KryptosAI

Context

forge test is green (189/189), but under forge coverage --ir-minimum one SubscriptionManager test fails (timestamp-sensitive assertion under coverage instrumentation, which disables via-ir optimizations). The coverage CI job is therefore continue-on-error: true. Current line coverage: 80.46% (494/614).

Proposed solution

  • Reproduce with forge coverage --ir-minimum --report summary in contracts/
  • Make the affected test robust to instrumentation (avoid exact block.timestamp equality; use vm.warp deltas / bounds)
  • Flip the job to blocking and add a minimum-coverage threshold (e.g. fail under 75% lines)

Acceptance criteria

  • forge coverage --ir-minimum exits 0
  • Coverage job required in CI with threshold

Effort: 1–2 hours.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions