What is the primary purpose of the @SpringBootTest annotation in Spring Boot testing?
- To configure application properties
- To define test data
- To specify test class paths
- To start the Spring application context
The @SpringBootTest annotation is primarily used to start the Spring application context, which enables you to test your Spring Boot application in an integrated way. It loads the complete application context and allows you to interact with it during testing.
Loading...
Related Quiz
- How can you alter the Bean Lifecycle methods in Spring?
- In Spring Boot, _____ annotation is used to map HTTP POST requests onto specific handler methods.
- How can you implement Token Enhancement to include additional information in the OAuth2 access token?
- In Spring Boot, the _____ annotation is used to denote a reactive programming model in a controller.
- In a Spring Boot application, how would you secure microservices using OAuth2 and JWT?