marketplace/bundles/pm-dev-java/skills/junit-core/SKILL.md
JUnit 5 core testing patterns with AAA structure, test organization, and coverage standards
npx skillsauth add cuioss/plan-marshall junit-coreInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
REFERENCE MODE: This skill provides reference material. Load specific standards on-demand based on current task.
JUnit 5 testing standards for general Java projects. This skill covers test structure, naming conventions, coverage requirements, and the AAA (Arrange-Act-Assert) pattern.
This skill applies to Java projects using JUnit 5:
org.junit.jupiter:junit-jupiter (JUnit 5)Important: Load this standard for any testing work.
Read: standards/testing-junit-core.md
This provides foundational rules for:
assertAll, assertInstanceOf, assertDoesNotThrow)Integration Testing (load for IT work):
Read: standards/testing-integration.md
Use when: Writing or reviewing integration tests (*IT.java). Covers naming, separation, and lifecycle.
Async Testing (load for async/concurrent code):
Read: standards/testing-async-patterns.md
Use when: Testing asynchronous behavior. Covers Awaitility patterns (never Thread.sleep).
Coverage Analysis (load for coverage work):
Read: standards/coverage-analysis-pattern.md
Use when: Analyzing test coverage or improving coverage metrics.
// CORRECT - At least one test class per production class
// TokenValidator.java → TokenValidatorTest.java
// UserService.java → UserServiceTest.java
@Test
@DisplayName("Should validate token with correct issuer")
void shouldValidateTokenWithCorrectIssuer() {
var issuer = Generators.nonBlankStrings().next();
var token = createTokenWithIssuer(issuer);
var result = validator.validate(token);
assertTrue(result.isValid(), "Token should be valid");
assertEquals(issuer, result.getIssuer(), "Issuer should match");
}
@Test
@DisplayName("Should parse all token claims")
void shouldParseAllTokenClaims() {
var token = createValidToken();
var claims = parser.parse(token);
assertAll("Token claims",
() -> assertNotNull(claims.getSubject(), "Subject should be present"),
() -> assertInstanceOf(Instant.class, claims.getExpiry(), "Expiry should be Instant"),
() -> assertFalse(claims.getRoles().isEmpty(), "Roles should not be empty")
);
}
plan-marshall:persona-module-tester - Language-agnostic testing principlespm-dev-java:junit-integration - Maven integration testingpm-dev-java-cui:cui-testing - CUI test generator frameworkpm-dev-java:java-core - Core Java patternsUnit test class — starting point for new test classes:
Read: templates/unit-test-class.java.tmpl
Replace ${PACKAGE}, ${CLASS_UNDER_TEST}, ${METHOD_1}, and placeholder comments with actual values.
| Standard | Purpose | |----------|---------| | testing-junit-core.md | Test structure, AAA pattern, assertions, nesting | | testing-integration.md | Integration test naming, separation, lifecycle | | testing-async-patterns.md | Awaitility patterns (never Thread.sleep) | | coverage-analysis-pattern.md | Coverage analysis and gap improvement |
development
Domain-owned OpenRewrite log-line finding parser for the java-cui domain — parses the
development
Domain-owned OpenRewrite marker detection for the java-cui domain — scans Java/Kotlin sources for cui-rewrite TODO markers, categorizes them by recipe, and fails the gate on any detected marker
development
Operator control surface for the marshalld build server — enrol/drop a project in the machine-global registry (the opt-in enable signal and anti-laundering wall), manage the daemon lifecycle (start, stop, drain, status, install, upgrade) version-pinned to the verified bundle copy, and inspect the daemon's per-project interaction-audit log (read-only)
tools
The tiny build-consumption client for the marshalld build server — submit a build job, bounded long-poll for its result, ping the daemon identity, and preflight registry-plus-liveness in one call; consumption only, never provisioning or enrolment