Package | Description |
---|---|
org.springframework.test.web.servlet |
Contains server-side support for testing Spring MVC applications.
|
org.springframework.test.web.servlet.client |
Support for testing Spring MVC applications via
WebTestClient
with MockMvc for server request
handling. |
org.springframework.test.web.servlet.setup |
Contains built-in
MockMvcBuilder implementations. |
Modifier and Type | Method and Description |
---|---|
protected MockMvc |
MockMvcBuilderSupport.createMockMvc(Filter[] filters,
MockServletConfig servletConfig,
WebApplicationContext webAppContext,
RequestBuilder defaultRequestBuilder,
Charset defaultResponseCharacterEncoding,
List<ResultMatcher> globalResultMatchers,
List<ResultHandler> globalResultHandlers,
List<DispatcherServletCustomizer> dispatcherServletCustomizers)
Delegates to
MockMvcBuilderSupport.createMockMvc(Filter[], MockServletConfig, WebApplicationContext, RequestBuilder, List, List, List)
for creation of the MockMvc instance and configures that instance
with the supplied defaultResponseCharacterEncoding . |
protected MockMvc |
MockMvcBuilderSupport.createMockMvc(Filter[] filters,
MockServletConfig servletConfig,
WebApplicationContext webAppContext,
RequestBuilder defaultRequestBuilder,
List<ResultMatcher> globalResultMatchers,
List<ResultHandler> globalResultHandlers,
List<DispatcherServletCustomizer> dispatcherServletCustomizers) |
Modifier and Type | Method and Description |
---|---|
<T extends B> |
MockMvcWebTestClient.MockMvcServerSpec.dispatcherServletCustomizer(DispatcherServletCustomizer customizer)
Allow customization of
DispatcherServlet . |
Modifier and Type | Method and Description |
---|---|
<T extends B> |
AbstractMockMvcBuilder.addDispatcherServletCustomizer(DispatcherServletCustomizer customizer) |
<T extends B> |
ConfigurableMockMvcBuilder.addDispatcherServletCustomizer(DispatcherServletCustomizer customizer)
A more advanced variant of
ConfigurableMockMvcBuilder.dispatchOptions(boolean) that allows
customizing any DispatcherServlet
property. |