Skip to content

chore(ci): scope coverage gate to well-covered crates#209

Open
rudyfraser wants to merge 1 commit into
mainfrom
fix/coverage-gate-scope
Open

chore(ci): scope coverage gate to well-covered crates#209
rudyfraser wants to merge 1 commit into
mainfrom
fix/coverage-gate-scope

Conversation

@rudyfraser

Copy link
Copy Markdown
Member

Problem

The coverage-pds job runs cargo llvm-cov --fail-under-lines 95 over rsky-pds plus the spaces/oauth crates and fails on every rsky-pds PR (e.g. #207, #208) regardless of the change. Two causes:

  1. Dependencies counted. llvm-cov instruments the whole dependency tree, so untested dependency crates (rsky-lexicon, rsky-repo, …) and bin main.rs entrypoints are counted at 0% and sink the total.
  2. rsky-pds isn't at 95%. Its large pre-existing untested surface (S3 blobstore, mailer, PLC, many legacy routes) sits ~72%, so a crate-wide 95% gate can't pass today.

Fix

  • Gate only rsky-oauth, rsky-space, rsky-space-host, rsky-daemon, with --ignore-filename-regex excluding dependency crates and main.rs. Measured locally: 99.80% lines — comfortably over 95%.
  • Report rsky-pds coverage informationally (no gate) while its coverage is driven up in a separate effort.

No source changes; CI-only.

Test plan

  • cargo llvm-cov --fail-under-lines 95 -p rsky-oauth -p rsky-space -p rsky-space-host -p rsky-daemon --ignore-filename-regex '(...)' → passes (99.80% lines) locally.

The coverage-pds job ran cargo llvm-cov --fail-under-lines 95 over
rsky-pds plus the spaces/oauth crates. llvm-cov instruments the whole
dependency tree, so untested dependency crates and bin main.rs entrypoints
were counted at 0%, and rsky-pds's large pre-existing untested surface
(S3, mailer, PLC, many routes) sat well under 95% — the gate failed on
every rsky-pds PR regardless of the change.

Gate only rsky-oauth/space/space-host/daemon (99.8% lines once deps and
main.rs are excluded via --ignore-filename-regex), and report rsky-pds
coverage informationally while it is driven up separately.
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.

1 participant