Testing Spring Boot Applications Demystified
summary
Spring Boot projects ship a starter-test that actually includes JUnit, Mockito, AssertJ, JSONAssert/JSONPath, XMLUnit and Awaitility, so unit tests focus on logic while slice testing (e.g., @WebMvcTest, @DataJpaTest) verifies HTTP mappings, validation and security without a full context. Integration tests run real services via testcontainers and either MockMvc or a real servlet on a random port. Build time often halves by optimizing context caching (example: 26 → 12 minutes) and mutation testing with PIT reveals blind spots beyond code‑coverage.
AI-written summary · about
chapters (17)
- 0:00Welcome and introduction
- 1:50Why automated testing matters
- 5:25Spring Boot testing overview
- 7:54Unit testing challenges
- 13:31Unit testing basics
- 16:46Unit test limitations
- 19:57Introducing slice testing
- 22:10Web layer slice testing
- 25:46Slice testing benefits
- 26:48Integration testing challenges
- 28:53Test containers for infrastructure
- 31:21Accessing application in tests
- 32:44Context caching amulet
- 38:00Optimizing context caching
- 40:13Test parallelization
- 43:02Mutation testing for quality
- 44:49Summary and closing
related talks
53mTesting Spring Boot Applications Demystified
33mThings I Wish I Knew When I Started Testing Spring Boot Applications
44mThings I Wish I Knew When I Started Testing Spring Boot Applications
51mTesting Spring Boot Applications
45mSpring Boot Test - A look behind the curtain
50mTesting Spring Boot Applications
02h 43mSpring Boot testing: Zero to Hero
01h 49mSpring Boot testing: Zero to Hero
