springboot-tdd

Installation
Summary

Test-driven development framework for Spring Boot with JUnit 5, Mockito, MockMvc, Testcontainers, and JaCoCo enforcement.

  • Covers unit tests (Mockito), web layer tests (MockMvc), integration tests (SpringBootTest), and persistence tests (DataJpaTest) with concrete examples
  • Integrates Testcontainers for production-mirroring Postgres/Redis databases and JaCoCo for enforcing 80%+ code coverage
  • Emphasizes Arrange-Act-Assert patterns, AssertJ assertions, and test data builders for maintainability
  • Targets feature additions, bug fixes, and refactoring workflows with CI commands for Maven and Gradle
SKILL.md

Spring Boot TDD Workflow

TDD guidance for Spring Boot services with 80%+ coverage (unit + integration).

When to Use

  • New features or endpoints
  • Bug fixes or refactors
  • Adding data access logic or security rules

Workflow

  1. Write tests first (they should fail)
  2. Implement minimal code to pass
  3. Refactor with tests green
  4. Enforce coverage (JaCoCo)

Unit Tests (JUnit 5 + Mockito)

Related skills
Installs
4.2K
GitHub Stars
179.7K
First Seen
Jan 30, 2026