/devco-agent-skills:e2efrom devco-agent-skills
Generates and runs end-to-end API tests for Spring Boot applications using Testcontainers, supporting both MVC (TestRestTemplate) and WebFlux (WebTestClient) patterns.
Ships in devco-agent-skills. Installing the plugin adds it to Claude Code.
Invokes slice-executor agent to generate, maintain, and execute end-to-end API tests using Testcontainers and TestRestTemplate (MVC) or WebTestClient (WebFlux).
Include in slice-executor agent prompt:
devco-agent-skills:bootstrap first. Before every file op, load matching skill and announce it.build.gradle for io.f8a.summer → if found, load devco-agent-skills:summer-core first, then devco-agent-skills:summer-test for Summer-specific test utilities.block() in src/main/. No git commit/push. No code without approved plan+spec.devco-agent-skills:testing-workflow for TDD cycle, StepVerifier, and Testcontainers patternsslice-executor agent will:
| Aspect | Spring Boot MVC | Spring WebFlux |
|---|---|---|
| Test Client | TestRestTemplate | WebTestClient |
| Database | JPA/Hibernate (JDBC) | R2DBC (Reactive) |
| Config | spring.datasource.* | spring.r2dbc.* |
| Async Testing | @Async + Awaitility | StepVerifier + Awaitility |
| Annotation | @SpringBootTest | @SpringBootTest + @AutoConfigureWebTestClient |
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@AutoConfigureWebTestClient
@Testcontainers
@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
class OrderPaymentFlowE2ETest {
@Container
static PostgreSQLContainer<?> postgres = new PostgreSQLContainer<>("postgres:15-alpine");
@Container
static GenericContainer<?> redis = new GenericContainer<>("redis:7-alpine")
.withExposedPorts(6379);
@DynamicPropertySource
static void configureProperties(DynamicPropertyRegistry registry) {
registry.add("spring.r2dbc.url", () ->
String.format("r2dbc:postgresql://%s:%d/%s",
postgres.getHost(), postgres.getFirstMappedPort(), postgres.getDatabaseName()));
registry.add("spring.r2dbc.username", postgres::getUsername);
registry.add("spring.r2dbc.password", postgres::getPassword);
}
@Autowired
private WebTestClient webTestClient;
@Test
@Order(1)
@DisplayName("User can create an order")
void shouldCreateOrder() {
webTestClient.post()
.uri("/api/orders")
.contentType(MediaType.APPLICATION_JSON)
.bodyValue(orderRequest)
.exchange()
.expectStatus().isCreated()
.expectBody()
.jsonPath("$.orderId").exists();
}
}
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@Testcontainers
@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
class OrderPaymentFlowMvcE2ETest {
@Container
static PostgreSQLContainer<?> postgres = new PostgreSQLContainer<>("postgres:15-alpine");
@DynamicPropertySource
static void configureProperties(DynamicPropertyRegistry registry) {
registry.add("spring.datasource.url", postgres::getJdbcUrl);
registry.add("spring.datasource.username", postgres::getUsername);
registry.add("spring.datasource.password", postgres::getPassword);
}
@Autowired
private TestRestTemplate restTemplate;
@Test
@Order(1)
@DisplayName("User can create an order")
void shouldCreateOrder() {
ResponseEntity<Map> response = restTemplate.postForEntity(
"/api/orders", orderRequest, Map.class);
assertThat(response.getStatusCode()).isEqualTo(HttpStatus.CREATED);
}
}
# Run all E2E tests
./gradlew test --tests "*E2ETest"
# Run specific test class
./gradlew test --tests "OrderPaymentFlowE2ETest"
# Run with verbose output
./gradlew test --tests "*E2ETest" --info
# Generate test report
./gradlew test jacocoTestReport
open build/reports/tests/test/index.html
dependencies {
testImplementation 'org.testcontainers:testcontainers:1.19.3'
testImplementation 'org.testcontainers:junit-jupiter:1.19.3'
testImplementation 'org.testcontainers:postgresql:1.19.3'
testImplementation 'org.testcontainers:kafka:1.19.3'
testImplementation 'org.testcontainers:r2dbc:1.19.3'
testImplementation 'org.awaitility:awaitility:4.2.0'
}
| Container | Image | Use Case |
|---|---|---|
| PostgreSQL | postgres:15-alpine | Database |
| Redis | redis:7-alpine | Cache |
| Kafka | confluentinc/cp-kafka:7.5.0 | Events |
| RabbitMQ | rabbitmq:3-management | Messaging |
DO:
@TestMethodOrder for dependent tests@DynamicPropertySource for container configs@DisplayName annotationsDON'T:
getFirstMappedPort())Thread.sleep() (use Awaitility)@AfterAllE2E Test Results
================
Status: ALL TESTS PASSED
Total: 10 tests
Passed: 10 (100%)
Failed: 0
Flaky: 0
Duration: 24.3s
Reports:
HTML Report: build/reports/tests/test/index.html
JaCoCo Coverage: build/reports/jacoco/test/html/index.html
CRITICAL (Must Always Pass):
IMPORTANT:
What the command file sets; muted values are Claude Code's defaults
7-day visitors to each command page
16 commands in this plugin
/alignGrill ambiguity, surface assumptions, extract vocabulary. Run before Plan when requirements vague (standard lane) or always (high-stakes lane). Output feeds Plan + Spec gates./brainstormTournament-style solution exploration. Generates 2-5 options with adversarial challenges, recommends with trade-offs. Mandatory high-stakes (≥3 options), conditional standard (multi-path)./buildExecute gate — dispatches one slice-executor subagent per plan slice (parallel where independent). Reads plan + spec + pre-flight 4 artifact. Lane-aware (trivial: direct execute, no dispatch).npx claudepluginhub taipt1504/agent-skills --plugin devco-agent-skillsOther plugins' commands for the same job