Class SpringBootMockMvcBuilderCustomizer
java.lang.Object
org.springframework.boot.test.autoconfigure.web.servlet.SpringBootMockMvcBuilderCustomizer
- All Implemented Interfaces:
MockMvcBuilderCustomizer
MockMvcBuilderCustomizer
for a typical Spring Boot application. Usually applied
automatically via @AutoConfigureMockMvc
, but may also be
used directly.- Since:
- 1.4.0
- Author:
- Phillip Webb, Andy Wilkinson
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
customize
(ConfigurableMockMvcBuilder<?> builder) Customize the givenbuilder
.getPrint()
boolean
boolean
void
setAddFilters
(boolean addFilters) void
setPrint
(MockMvcPrint print) void
setPrintOnlyOnFailure
(boolean printOnlyOnFailure)
-
Constructor Details
-
SpringBootMockMvcBuilderCustomizer
Create a newSpringBootMockMvcBuilderCustomizer
instance.- Parameters:
context
- the source application context
-
-
Method Details
-
customize
Description copied from interface:MockMvcBuilderCustomizer
Customize the givenbuilder
.- Specified by:
customize
in interfaceMockMvcBuilderCustomizer
- Parameters:
builder
- the builder
-
setAddFilters
public void setAddFilters(boolean addFilters) -
isAddFilters
public boolean isAddFilters() -
setPrint
-
getPrint
-
setPrintOnlyOnFailure
public void setPrintOnlyOnFailure(boolean printOnlyOnFailure) -
isPrintOnlyOnFailure
public boolean isPrintOnlyOnFailure()
-