spring-boot-testing

Solid

Expert Spring Boot 4 testing specialist that selects the best Spring Boot testing techniques for your situation with Junit 6 and AssertJ.

Testing & QA 34,158 stars 4179 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 93/100

Stars 20%
100
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Spring Boot Testing This skill provides expert guide for testing Spring Boot 4 applications with modern patterns and best practices. ## Core Principles 1. **Test Pyramid**: Unit (fast) > Slice (focused) > Integration (complete) 2. **Right Tool**: Use the narrowest slice that gives you confidence 3. **AssertJ Style**: Fluent, readable assertions over verbose matchers 4. **Modern APIs**: Prefer MockMvcTester and RestTestClient over legacy alternatives ## Which Test Slice? | Scenario | Annotation | Reference | |----------|------------|-----------| | Controller + HTTP semantics | `@WebMvcTest` | [references/webmvctest.md](references/webmvctest.md) | | Repository + JPA queries | `@DataJpaTest` | [references/datajpatest.md](references/datajpatest.md) | | REST client + external APIs | `@RestClientTest` | [references/restclienttest.md](references/restclienttest.md) | | JSON (de)serialization | `@JsonTest` | [references/test-slices-overview.md](references/test-slices-overview.md) | | Full application | `@SpringBootTest` | [references/test-slices-overview.md](references/test-slices-overview.md) | ## Test Slices Reference - [references/test-slices-overview.md](references/test-slices-overview.md) - Decision matrix and comparison - [references/webmvctest.md](references/webmvctest.md) - Web layer with MockMvc - [references/datajpatest.md](references/datajpatest.md) - Data layer with Testcontainers - [references/restclienttest.md](references/restclienttest.md) - REST client testing...

Details

Author
github
Repository
github/awesome-copilot
Created
11 months ago
Last Updated
yesterday
Language
Python
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category

Testing & QA Solid

spring-boot-test-patterns

Provides comprehensive testing patterns for Spring Boot applications covering unit, integration, slice, and container-based testing with JUnit 5, Mockito, Testcontainers, and performance optimization. Use when writing tests, @Test methods, @MockBean mocks, or implementing test suites for Spring Boot applications.

261 Updated 1 weeks ago
giuseppe-trisciuoglio
Testing & QA Solid

321-frameworks-spring-boot-testing-unit-tests

Use when you need to write unit tests for Spring Boot applications — including pure unit tests with @ExtendWith(MockitoExtension.class) for @Service/@Component, slice tests with @WebMvcTest and @MockitoBean for controllers, @JsonTest for JSON serialization, parameterized tests with @CsvSource/@MethodSource, test profiles, and @TestConfiguration. For framework-agnostic Java use @131-java-testing-unit-testing. For integration tests use @322-frameworks-spring-boot-testing-integration-tests. Part of the skills-for-java project

393 Updated today
jabrena
Testing & QA Solid

322-frameworks-spring-boot-testing-integration-tests

Use when you need to write or improve integration tests — including Testcontainers with @ServiceConnection, @DataJdbcTest persistence slices, TestRestTemplate or MockMvcTester for HTTP, data isolation, and container lifecycle management for Spring Boot 4.0.x. Part of the skills-for-java project

393 Updated today
jabrena
Testing & QA Listed

testing-patterns

Backend testing patterns with JUnit 6, Mockito 6, Testcontainers 2.0, Spring Boot slice tests, RestTestClient, and security testing. Use when user mentions testing, coverage, TDD, integration tests, or "write tests for".

0 Updated today
IuliaIvanaPatras
Testing & QA Solid

springboot-tdd

Test-driven development for Spring Boot using JUnit 5, Mockito, MockMvc, Testcontainers, and JaCoCo. Use when adding features, fixing bugs, or refactoring.

495 Updated 1 months ago
vibeeval