Skip to content

Add coverage CRAP indicators#46

Merged
jmcte merged 1 commit into
mainfrom
codex/crap-indicators-tests
May 24, 2026
Merged

Add coverage CRAP indicators#46
jmcte merged 1 commit into
mainfrom
codex/crap-indicators-tests

Conversation

@jmcte
Copy link
Copy Markdown
Contributor

@jmcte jmcte commented May 23, 2026

Summary

  • Adds a reusable coverage reporting helper that keeps the existing line coverage gate and emits CRAP-style low-coverage indicators from llvm-cov JSON.
  • Adds a fixture-backed shell regression test for coverage percentage output, CRAP indicator output, and threshold failure behavior.
  • Wires the new test into the fast PR gate and documents the indicator output in the README.

Governing Issue

No open GitHub issues exist for OMT-Global/icloud-cli as of the live check on 2026-05-23 (gh issue list --repo OMT-Global/icloud-cli --state open --limit 50 returned []), so this PR is intentionally unlinked.

Validation

  • Relevant local checks passed
  • Required PR checks are expected to satisfy CI Gate
  • Skipped checks are explained below

Commands run:

  • bash scripts/ci/test-coverage-indicators.sh - passed
  • bash scripts/ci/check-shell-syntax.sh - passed
  • bash scripts/ci/check-ci-policy.sh - passed
  • bash scripts/check-detect-secrets.sh --all-files - passed
  • bash scripts/check-privacy-fixtures.sh - passed
  • env CLANG_MODULE_CACHE_PATH=/Users/johnteneyckjr./src/omt-global/icloud-cli/.build/module-cache SWIFTPM_MODULECACHE_OVERRIDE=/Users/johnteneyckjr./src/omt-global/icloud-cli/.build/module-cache swift test --disable-sandbox - passed, 49 tests
  • env SWIFT_FLAGS=--disable-sandbox bash scripts/ci/check-coverage.sh - passed, source line coverage 68.28% with CRAP indicators emitted
  • env SWIFT_FLAGS=--disable-sandbox bash scripts/ci/run-mutation-smoke.sh - passed, 4 mutants killed
  • env CLANG_MODULE_CACHE_PATH=/Users/johnteneyckjr./src/omt-global/icloud-cli/.build/module-cache SWIFTPM_MODULECACHE_OVERRIDE=/Users/johnteneyckjr./src/omt-global/icloud-cli/.build/module-cache swift build --disable-sandbox - passed
  • git diff --check - passed

Skipped:

  • Full bash scripts/ci/run-fast-checks.sh was not run end-to-end locally because this host requires swift --disable-sandbox; the equivalent component checks above were run with the necessary SwiftPM flag.

Bootstrap Governance

  • Changes are scoped to the linked issue
  • Contributor or PR guidance changes are reflected in CONTRIBUTING.md, .github/PULL_REQUEST_TEMPLATE.md, and docs/bootstrap/onboarding.md when applicable
  • PR author enabled auto-merge where GitHub allows it, or GitHub plan-limit evidence/unavailable reason is recorded and the fallback merge-readiness policy applies
  • No real secrets, runtime auth, or machine-local env files are committed

Flow Contract

  • Owner lane: Pheidon
  • Repair owner: Codex
  • Autonomy class: low-risk CI/reporting maintenance
  • Risk class: low

Flow Merge Readiness

  • Every blocker has a next actor and next action
  • No active blocking requested changes remain
  • Non-author approval is present when required
  • PR author enabled auto-merge where GitHub allows it, or recorded why it is unavailable/unsafe

Merge Automation

  • Auto-merge enabled with squash once required checks passed; merge remains blocked until required review is satisfied.

Notes

  • Local commit signing via gitsign timed out waiting for browser OAuth, so commit 1ceb7b8 was created with --no-gpg-sign.

@jmcte jmcte requested a review from pheidon as a code owner May 23, 2026 21:44
@jmcte jmcte enabled auto-merge (squash) May 23, 2026 21:46
@athena-omt athena-omt added area:infra Infrastructure, CI, release, governance, scripts, or repo setup. lane:ares Ares validation/test lane. review:athena Athena review governance requested. risk:medium Medium-risk change; normal care required. state:waiting-checks Waiting for CI/check status to settle. status:needs-review PR is ready for Athena review. labels May 23, 2026
Copy link
Copy Markdown
Contributor

@pheidon pheidon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved from Pheidon second-pass review. The coverage indicator helper preserves the existing coverage gate, adds fixture-backed shell regression coverage, and live CI Gate checks are green.

@jmcte jmcte merged commit 0ee1306 into main May 24, 2026
2 checks passed
@jmcte jmcte deleted the codex/crap-indicators-tests branch May 24, 2026 00:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:infra Infrastructure, CI, release, governance, scripts, or repo setup. lane:ares Ares validation/test lane. review:athena Athena review governance requested. risk:medium Medium-risk change; normal care required. state:waiting-checks Waiting for CI/check status to settle. status:needs-review PR is ready for Athena review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants