Class MockMvcConfigurerAdapter
- java.lang.Object
- org.springframework.test.web.servlet.setup.MockMvcConfigurerAdapter
- All Implemented Interfaces:
MockMvcConfigurer
public abstract class MockMvcConfigurerAdapter extends Object implements MockMvcConfigurer
An empty method implementation ofMockMvcConfigurer
.- Since:
- 4.1
- Author:
- Rossen Stoyanchev
Constructor Summary
Constructors Constructor Description MockMvcConfigurerAdapter()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterConfigurerAdded(ConfigurableMockMvcBuilder<?> builder)
Invoked immediately after aMockMvcConfigurer
is added viaConfigurableMockMvcBuilder.apply(org.springframework.test.web.servlet.setup.MockMvcConfigurer)
.RequestPostProcessor
beforeMockMvcCreated(ConfigurableMockMvcBuilder<?> builder, WebApplicationContext cxt)
Invoked just before the MockMvc instance is created.
Constructor Detail
MockMvcConfigurerAdapter
public MockMvcConfigurerAdapter()
Method Detail
afterConfigurerAdded
public void afterConfigurerAdded(ConfigurableMockMvcBuilder<?> builder)
Description copied from interface:MockMvcConfigurer
Invoked immediately after aMockMvcConfigurer
is added viaConfigurableMockMvcBuilder.apply(org.springframework.test.web.servlet.setup.MockMvcConfigurer)
.- Specified by:
afterConfigurerAdded
in interfaceMockMvcConfigurer
beforeMockMvcCreated
public RequestPostProcessor beforeMockMvcCreated(ConfigurableMockMvcBuilder<?> builder, WebApplicationContext cxt)
Description copied from interface:MockMvcConfigurer
Invoked just before the MockMvc instance is created. Implementations may return a RequestPostProcessor to be applied to every request performed through the createdMockMvc
instance.- Specified by:
beforeMockMvcCreated
in interfaceMockMvcConfigurer