Skip to content

ci(swift): assert coverage with lcovcheck instead of grep - #72

Merged
walterjgsp merged 1 commit into
swiftfrom
ci/swift-lcovcheck
Oct 4, 2026
Merged

walterjgsp merged 1 commit into
swiftfrom
ci/swift-lcovcheck

Conversation

@walterjgsp

Copy link
Copy Markdown
Contributor

Item 4 of #66, for the swift rules. The coverage smoke steps used grep -E on Please's console table (a human format that differs between Please versions and is not printed the same on cache hits) and on the raw .lcov text.

  • Per-file coverage: lcovcheck -coverage-json plz-out/log/coverage.json -covered <file> (structured, no console parsing).
  • Raw .lcov export: lcovcheck -lcov ... -path ... -line N=status -function NAME=hit|missed|N on the shared parser, so a line is asserted to be covered, uncovered or partial instead of matching a BRDA record by text.

The assertions are the same facts as before (and a few more: the uncovered line), and I ran the built binary against this fixture's real output, and against a real coverage.json, before writing them. lcovcheck itself comes from main (#68), already synced here.

🤖 Generated with Claude Code

The smoke steps grepped Please's console coverage table and the raw .lcov text. Use lcovcheck: Please's coverage.json for the per-file coverage, and the shared lcov parser for line statuses and function hits of the exported report. Item 4 of #66.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@walterjgsp
walterjgsp merged commit bfea7f5 into swift Oct 4, 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