Modern Testing in Java

Course Length: 4 Days

Modern Testing in Java is a four-day hands-on workshop that explores how testing practices in the Java ecosystem have evolved beyond traditional unit testing. Participants will learn to design systems through tests using Test-Driven Development (TDD), validate behavior with expressive assertions using AssertJ, and expand their testing capabilities with Property-Based Testing using Jqwik. The course emphasizes building confidence in real systems by testing against real infrastructure using Testcontainers rather than relying solely on mocks.

Throughout the workshop, attendees will progress from foundational testing techniques to advanced practices, including behavior-driven development, repository and service integration testing, and full-layer testing strategies. The course concludes by exploring emerging approaches, such as Spec-Driven Development with AI, in which business specifications guide automated planning and validation of implementation. By the end of the workshop, participants will have a practical toolkit for building robust, maintainable, and well-tested Java applications.

This four-day immersive workshop focuses on modern approaches to testing Java applications, combining proven engineering practices with emerging techniques that leverage automation and AI-assisted development.

The workshop begins with Test Driven Development (TDD) as the foundation of modern testing. Participants will learn how to design code through tests using clear, expressive assertions with AssertJ, focusing on writing tests that drive better design and maintainability.

From there, the course expands testing beyond example-based tests into Property-Based Testing using Jqwik. Instead of testing a few specific cases, attendees will learn how to define system properties and automatically generate thousands of inputs to discover edge cases. Participants will learn how to build custom Arbitraries to generate realistic data and validate complex business rules.

Next, the workshop moves into integration testing with real infrastructure using Testcontainers. Attendees will learn how to test persistence layers by spinning up real databases in containers and validating repository behavior against real environments. This approach is then extended to testing multiple layers of an application—including repositories, services, controllers, and even load scenarios—to ensure the entire system behaves correctly.

A critical section of the workshop examines mocking versus real integration testing, discussing when mocks are useful, when they introduce risk, and how modern tooling allows developers to test real dependencies more reliably.

The workshop also reintroduces Behavior Driven Development (BDD) to help teams express requirements as executable specifications. Participants will see how business scenarios can guide both development and testing, particularly now that AI is in high-demand

Finally, the course explores an emerging practice: Spec-Driven Development with AI. In this approach, business specifications (often written as BDD-style scenarios) serve as the source of truth that guides implementation. AI tools can generate technical plans and tasks based on these specifications, while tests ensure that the resulting implementation satisfies the original behavior.

By the end of the workshop, participants will understand how modern testing techniques—from TDD and property-based testing to containerized integration testing and AI-assisted development—work together to produce reliable, maintainable, and well-tested Java systems.