Java Test
| This documentation was generated with the assistance of AI. Please report any inaccuracies. |
Run a Java project’s JUnit test suite through the Maven Surefire plugin (mvn test), scoped to whatever the
caller asked for — everything, a single class, a single method, a wildcard/package pattern, or a JUnit 5 tag
expression. This is a read-only reporting skill: it runs tests and summarizes the outcome, it does not fix
failures unless asked to as an explicit follow-up.
Purpose
iru-java-test turns a loosely-specified request ("run the FooTest", "just the fast tests", "everything") into the
correct Surefire invocation and a concise pass/fail summary. It exists so that running and narrowing down tests
doesn’t require hand-composing -Dtest/-Dgroups syntax each time, and so that a calling skill (or a human) gets
back a short report instead of a full raw Maven log.
Inputs
| Argument | Required | Description | Default |
|---|---|---|---|
|
No |
Names what to run: a test class, a class+method, several classes, a wildcard/package pattern, an exclusion, or a JUnit 5 tag expression. Mapped to the correct Surefire parameter per the table below. |
None — omitting it runs the full suite ( |
The selector maps to Surefire parameters as follows:
| What the user wants | Parameter | Example |
|---|---|---|
Everything |
(none) |
|
One test class |
|
|
One method in a class |
|
|
Several methods in one class |
|
|
Several classes |
|
|
Classes matching a name pattern |
|
|
All classes in a package |
|
|
Excluding some classes/methods |
|
|
Tests tagged with a JUnit 5 |
|
|
Excluding a JUnit 5 tag |
|
|
Tag boolean expression |
|
|
#method selection and -Dgroups/-DexcludedGroups tag filtering require JUnit 4.x, JUnit 5, or TestNG (not
plain JUnit 3) — the skill checks the project’s pom.xml if it’s unsure which syntax applies. A selector that
matches nothing fails the build with "No tests matching pattern…"; -DfailIfNoSpecifiedTests=false is only
added when the user explicitly wants a missing-selector to be a silent no-op.
Outputs
-
A plain-text summary in the conversation — never a written file.
-
Total tests run, failures, errors, and skipped counts.
-
If everything passed: a brief confirmation, without pasting the full log.
-
If there are failures/errors: the failing test names and the relevant assertion/exception output (falling back to
target/surefire-reports/*.txtif console output was truncated) — without unrelated passing-test noise. -
No source or test code is ever modified.
Execution flow
Dependencies
Invokes
None — iru-java-test is a leaf skill; it only runs Maven commands and reports on their output, 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 run the scoped tests for every class the bucket affected (falling back tomvn test -Dtest=<TestClass>directly if this skill is unavailable), plus a full-suite run.
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.