Skip to content

knowledgefactory4u/spring-boot-test-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spring Boot Testing examples

1. @RestClientTest

Testing REST Clients With @RestClientTest

2. @JsonTest

Testing JSON Serialization and Deserialization With @JsonTest

3. @WebFluxTest

Testing Spring WebFlux Controller with @WebFluxTest

4. @WebMvcTest

Testing Spring Web Controller with @WebMvcTest

5. @DataJpaTest

Testing a JPA application With @DataJpaTest

6. @DataJdbcTest

Testing Spring Data JDBC application with @DataJdbcTest

7. @JdbcTest

Testing JDBC components with @JdbcTest

8. @DataMongoTest

Testing a MongoDB application with @DataMongoTest

9. Integration Testing with Testcontainers

Spring Boot 3 + PostgreSQL - Integration Testing with Testcontainers - Example

10. Testing a JPA application with @DataJpaTest and Testcontainers

Testing a JPA application with @DataJpaTest and Testcontainers

11. Spring Boot MongoDB - Integration Testing with Testcontainers

Spring Boot MongoDB - Integration Testing with Testcontainers

12. Testing a Data MongoDB application with Testcontainers and @DataMongoTest

Spring Boot - Testing a Data MongoDB application with Testcontainers and @DataMongoTest

Local setup

Step 1: Download or clone the source code from GitHub to the local machine

Step 2: mvn clean install

Step 3: mvn test