Skip to content

fix(rust): pass the configured llvm tools to rust_test; document coverage - #45

Merged
walterjgsp merged 8 commits into
rustfrom
fix/coverage-rust
Oct 3, 2026
Merged

walterjgsp merged 8 commits into
rustfrom
fix/coverage-rust

Conversation

@walterjgsp

@walterjgsp walterjgsp commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Fix: rust_test read LlvmProfdataTool, LlvmCovTool and Coverage with CONFIG.get("RUST.X"), which does not see plugin config. test_tools held only the runner, so llvm-profdata came from the host. On the GitHub runner that was LLVM 16 and plz cover reported lib.rs 0/3 (unsupported instrumentation profile format version); locally it only worked because the host LLVM was new. Now read as CONFIG.RUST.<KEY>.
  • The coverage error names the llvm-profdata that failed.
  • Documents report location, format and contents, and the silent No data without [cover] fileextension = .rs.
  • CI coverage smoke test (this is what caught the bug). Changelog is under [Unreleased]; no release is planned.

Test plan

  • plz cover //test/rust/lib:lib_test: lib.rs 3/3; plz test //tools/... //test/... passes
  • CI on the runner: lib.rs 3/3 lines

Refs #41

🤖 Generated with Claude Code

walterjgsp and others added 8 commits October 3, 2026 08:52
Document report location, format and contents, and add a CI coverage smoke test.

Refs #41

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Refs #41

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
plz prints the coverage table on stderr, so tee saw nothing. Also show test output to diagnose a 0% result seen on the runner.

Refs #41

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Diagnose a 0% result seen only on the runner.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Report the resolved path and version in the coverage error to diagnose a runner-only failure; print the host rustc in the smoke step.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
CONFIG.get("RUST.X") does not read plugin config, so LlvmProfdataTool, LlvmCovTool and Coverage were ignored: test_tools held only the runner and llvm-profdata was found on the host. On a runner with an older host LLVM the merge failed ("unsupported instrumentation profile format version") and coverage was 0%. Read the keys as CONFIG.RUST.<KEY>.

Refs #41

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@walterjgsp walterjgsp changed the title docs(rust): document coverage report output and add smoke test fix(rust): pass the configured llvm tools to rust_test; document coverage Oct 3, 2026
@walterjgsp
walterjgsp merged commit 0db036c into rust Oct 3, 2026
2 checks passed
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