JVM Testing Toolbox — an AI agent skill
Renamed from java-testing-toolbox. The skill now covers Kotlin too, for
mixed Java+Kotlin projects; its directory and skill name are
jvm-testing-toolbox.
An agent skill that helps AI coding
tools (Claude Code, Cursor, Copilot, …) pick the right JVM testing tool for a
given challenge in a Java and/or Kotlin project — the right framework,
assertion library, mocking approach, or HTTP / infrastructure / browser / BDD /
architecture tool — with the selection tie-breakers and pitfalls that generic
model knowledge tends to miss.
It's a router, not a tutorial: it deliberately does not re-teach things an
LLM already knows (basic JUnit 5 / Mockito / AssertJ usage). Its value is the
map — "for problem X, tools Y and Z exist; pick Y because…".
Credit
This skill began as a distillation of Philip Riecks'
book, and his selection and categorization are still its backbone:
Java Testing Toolbox: 30 Testing Tools and Libraries Every Java Developer
Must Know — Philip Riecks
It has since diverged, so please don't read the whole of it as his work:
- Curated. Several of the book's tools were dropped and the list re-tiered
around what JVM teams reach for most — see Coverage above for each cut and its
reason.
- Extended. Playwright, Cucumber, and the entire Kotlin side (MockK,
kotlinx-coroutines-test, and the Java/Kotlin interop
notes) are additions the book doesn't cover — it is Java-framed.
- Updated. Version-sensitive guidance is re-checked against current release
notes and corrected where the ecosystem moved — JUnit 6 as the default, and
Mockito 5 making the inline mock-maker standard, among others.
The Java tool selection, the categorization, and the pitfalls distilled from the
book are Philip's. The cuts, the additions, and any errors in them are mine.
Please support the original work:
This repository contains no reproduction of the book's prose or source code —
it is an original, condensed decision map that points back to Philip's material
for the depth and runnable examples. If you find it useful, buy the book.
Packaged and maintained by Aditya Parikh (@adityamparikh).
What's inside
.claude/skills/jvm-testing-toolbox/ ← canonical content
├── SKILL.md # the router: problem → tool decision tables
└── references/
├── tool-cards.md # one card per tool: purpose + the one high-signal note
├── pitfalls.md # cross-cutting gotchas + tie-breaker rationale
└── kotlin.md # Kotlin depth + Java/Kotlin interop in one source set
AGENTS.md ← index + pointer (most agents)
.github/instructions/jvm-testing.instructions.md ← index + pointer (Copilot)
.cursor/rules/jvm-testing.mdc ← index + pointer (Cursor)
Which agents this works with
The routing tables are written for Claude Code's skill format, which loads
SKILL.md only when a testing question matches its description and pulls
references/* only once routing lands. That progressive disclosure is the design —
it keeps 170 lines of tables out of context on unrelated work.
Other agents get pointer files, each using that agent's own gating so the content
isn't always-loaded:
| File | Read by | Gating |
|---|
AGENTS.md | Codex, Cursor, Copilot, Gemini CLI, Aider, Windsurf, Zed, Devin, Jules, VS Code, Junie — and Claude Code | always loaded, so it stays short |
.github/instructions/jvm-testing.instructions.md | GitHub Copilot | applyTo globs — test sources only |
.cursor/rules/jvm-testing.mdc | Cursor | globs + alwaysApply: false — auto-attaches on test files |
None of them restate the tool list. A copy would drift from the router the first
time a tool is added or dropped, and a stale index is worse than no index — so the
routing tables live in exactly one place.
How each avoids duplicating them differs, because the mechanisms differ:
- Cursor supports
@filename includes, so the rule is a genuine pointer: it
@-references SKILL.md and the three reference files and states nothing itself.
- Copilot and AGENTS.md have no include mechanism, so they instruct the agent
to read
SKILL.md and carry only a handful of silent-failure traps — JUnit 4/Jupiter
mixing, junit-bom alignment, two mockers on one type, Thread.sleep. Those are
stable enough to survive tool-list churn, which the index is not.