Problem
generate-coverage hard-codes cargo llvm-cov --workspace (see
get_cargo_coverage_cmd in run_rust.py) with no way to exclude
crates or pass extra cargo arguments. Workspaces whose test suite
cannot run as a bare --workspace build cannot adopt the action —
and therefore cannot use with-ratchet, which lives inside it.
Observed live during the CodeScene coverage rollout on
leynos/whitaker (whitaker#274): make test excludes eleven crates
(seven rustc_* proxy shims, the root crate, and three lint crates
whose dylint UI tests need per-target
-C prefer-dynamic -Z force-unstable-if-unmarked RUSTFLAGS). The
workaround is a Makefile coverage target that reuses the test
recipe with a TEST_RUNNER swap to llvm-cov nextest --lcov, plus
the standalone upload-codescene-coverage action — with the ratchet
left off.
Proposal
Add an extra-cargo-args (or exclude) input to generate-coverage
that is appended to the cargo llvm-cov invocation, so
exclusion-heavy workspaces can adopt the action and its ratchet.
Default behaviour unchanged.
Affected consumers
- leynos/whitaker (confirmed; see whitaker#274 for the workaround)
- any workspace whose CI-tested crate subset differs from
--workspace (the mutation-testing rollout catalogued several:
CI-excluded crates, path-dep fixtures, vendored patch crates).
Related: #335 (language-detection override) — same theme of
detect/command inflexibility blocking adoption.
Problem
generate-coveragehard-codescargo llvm-cov --workspace(seeget_cargo_coverage_cmdinrun_rust.py) with no way to excludecrates or pass extra cargo arguments. Workspaces whose test suite
cannot run as a bare
--workspacebuild cannot adopt the action —and therefore cannot use
with-ratchet, which lives inside it.Observed live during the CodeScene coverage rollout on
leynos/whitaker (whitaker#274):
make testexcludes eleven crates(seven
rustc_*proxy shims, the root crate, and three lint crateswhose dylint UI tests need per-target
-C prefer-dynamic -Z force-unstable-if-unmarkedRUSTFLAGS). Theworkaround is a Makefile
coveragetarget that reuses the testrecipe with a
TEST_RUNNERswap tollvm-cov nextest --lcov, plusthe standalone
upload-codescene-coverageaction — with the ratchetleft off.
Proposal
Add an
extra-cargo-args(orexclude) input togenerate-coveragethat is appended to the
cargo llvm-covinvocation, soexclusion-heavy workspaces can adopt the action and its ratchet.
Default behaviour unchanged.
Affected consumers
--workspace(the mutation-testing rollout catalogued several:CI-excluded crates, path-dep fixtures, vendored patch crates).
Related: #335 (language-detection override) — same theme of
detect/command inflexibility blocking adoption.