Class MockMvcAutoConfiguration
java.lang.Object
org.springframework.boot.test.autoconfigure.web.servlet.MockMvcAutoConfiguration
@AutoConfiguration(after={org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration.class,WebTestClientAutoConfiguration.class})
@ConditionalOnWebApplication(type=SERVLET)
@EnableConfigurationProperties({org.springframework.boot.autoconfigure.web.ServerProperties.class,org.springframework.boot.autoconfigure.web.servlet.WebMvcProperties.class})
public class MockMvcAutoConfiguration
extends Object
Auto-configuration for
MockMvc
.- Since:
- 1.4.0
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.web.servlet.DispatcherServlet
dispatcherServlet
(org.springframework.test.web.servlet.MockMvc mockMvc) org.springframework.boot.autoconfigure.web.servlet.DispatcherServletPath
org.springframework.test.web.servlet.MockMvc
mockMvc
(org.springframework.test.web.servlet.MockMvcBuilder builder) org.springframework.test.web.servlet.setup.DefaultMockMvcBuilder
mockMvcBuilder
(List<MockMvcBuilderCustomizer> customizers)
-
Method Details
-
dispatcherServletPath
@Bean @ConditionalOnMissingBean public org.springframework.boot.autoconfigure.web.servlet.DispatcherServletPath dispatcherServletPath() -
mockMvcBuilder
@Bean @ConditionalOnMissingBean(org.springframework.test.web.servlet.MockMvcBuilder.class) public org.springframework.test.web.servlet.setup.DefaultMockMvcBuilder mockMvcBuilder(List<MockMvcBuilderCustomizer> customizers) -
springBootMockMvcBuilderCustomizer
@Bean @ConfigurationProperties(prefix="spring.test.mockmvc") public SpringBootMockMvcBuilderCustomizer springBootMockMvcBuilderCustomizer() -
mockMvc
@Bean @ConditionalOnMissingBean public org.springframework.test.web.servlet.MockMvc mockMvc(org.springframework.test.web.servlet.MockMvcBuilder builder) -
dispatcherServlet
@Bean @ConditionalOnMissingBean public org.springframework.web.servlet.DispatcherServlet dispatcherServlet(org.springframework.test.web.servlet.MockMvc mockMvc)
-