Intermediate Package

The intermediate package helps you to write both integration and end-to-end tests for Spring web applications. This package consists of nine topics:

The Introduction to Integration Testing topic describes how you can create different source and resource directories for your unit and integration tests, and explains how you can run your tests with Maven and Gradle.

The Introduction to DbUnit topic helps you to create DbUnit data sets which are easy to read, write and maintain. To be more specific, you will learn how you can insert the required test data into your database, write assertions for the data found from your database, and reduce duplicate constants by using constant classes.

The Configuring Our Integration Tests topic helps you to configure the application context of your integration tests when you are writing integration tests for Spring and Spring Boot web applications. You will learn to integrate DbUnit with the Spring Test framework and customize its configuration. This topic also describes how you can configure the Spring MVC Test framework and integrate Spring Security with it. Finally, you will learn how you can use different application context configuration when you run your application and when you run your integration tests.

The Writing Integration Tests for Spring Web Applications topic helps you to learn the skills you need when you are writing integration tests for both normal Spring MVC web applications and Spring MVC REST APIs. This topic describes how you can use DbUnit data sets in your integration tests, and helps you to write integration tests for your repositories and Spring MVC controllers.

The Introduction to End-to-End Testing topic describes how you can create different source and resource directories for your unit, integration, and end-to-end tests. You will also learn how you can run your tests with Maven and Gradle. Finally, this lesson provides a quick introduction to Selenium WebDriver.

The Configuring Our End-to-End Tests topic describes how you configure end-to-end tests when you are writing end-to-end tests for a Spring or a Spring Boot web application. You will also learn to initialize your database into a known state by using both Liquibase and the @Sql annotation.

The The Writing End-to-End Tests for Spring Web Applications topic helps you to write end-to-end tests for normal web applications. This topic starts by explaining how you can find elements from HTML documents and control Selenium WebDriver. After you are familiar with the basics, you will learn to reduce duplicate code by creating page objects. Finally, this topic describes how you can write end-to-end tests for normal web applications.

The Writing End-to-End Tests for Javascript Web Applications topic describes what kind of techniques you have to use when you are writing end-to-end tests for Javascript web applications with Selenium WebDriver.

The Bonus Webinars topic contains the bonus webinars that were recording during 2017. These webinars help you to mock and stub external REST APIs, and describe how you can get started with Junit 5.