Java Coverage
| This documentation was generated with the assistance of AI. Please report any inaccuracies. |
Run JaCoCo against a scoped (or full) test run via mvn clean jacoco:prepare-agent test jacoco:report, then read
the generated target/site/jacoco/jacoco.csv to report the exact, measured line-coverage percentage for the
specific class(es) the caller cares about. This is a read-only reporting skill: it measures and reports coverage,
it does not add tests or modify source/test code unless asked to as an explicit follow-up.
Purpose
iru-java-coverage answers "does class X meet the coverage bar?" with an exact, CSV-derived percentage instead of an
eyeballed guess from Surefire output. It reuses `iru-java-test’s selector syntax to scope which tests run, infers or
accepts an explicit list of target classes, and — for classes under the bar — points to the exact uncovered
lines/branches in the per-class HTML report so a follow-up can target them precisely.
Inputs
| Argument | Required | Description | Default |
|---|---|---|---|
|
No |
Which tests to run, using the exact same syntax as the |
None — omitting it runs the full suite. |
|
No |
Comma-separated class name(s) to report coverage for. |
None — if omitted, target classes are inferred from the test selector by convention ( |
Outputs
-
A plain-text summary in the conversation — never a written file.
-
Per target class: exact line-coverage percentage (and branch coverage where relevant), computed directly from
target/site/jacoco/jacoco.csv— never estimated. -
If the user gave a coverage bar (e.g. "at least 80%"): a clear statement of whether each class meets it.
-
For classes under the bar: a pointer to the per-class HTML/
.java.htmlreport and the exact uncovered line numbers (via thenc/pc/fcspan classes) rather than just the aggregate percentage. -
A class absent from the CSV is reported as 0% coverage, not as an error.
-
No source or test code is ever modified, and coverage is never re-run to try to raise a number.
Execution flow
Dependencies
Invokes
None — iru-java-coverage is a leaf skill; it only runs Maven commands and reads the generated JaCoCo reports, it
does not call any other skill in this catalog.
Invoked by
-
Java Code One Task Group — Step 3, once per task group’s bucket, via the
iru-gate-runneragent, to check every changed/new class in the bucket meets the 80% coverage bar (falling back tomvn jacoco:prepare-agent test jacoco:reportdirectly if this skill is unavailable).
Related agents
-
iru-gate-runner—iru-java-code-one-task-group(see Java Code One Task Group) always invokes this skill from inside airu-gate-runnersub-agent it spawns, not inline.
Source
SKILL.md on GitHub — the file this page was generated from.