Interface WebTestClientConfigurer
public interface WebTestClientConfigurer
Contract to encapsulate customizations to a
WebTestClient.Builder
.
Typically used by frameworks that wish to provide a shortcut for common
initialization.- Since:
- 5.0
- Author:
- Rossen Stoyanchev
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
afterConfigurerAdded
(WebTestClient.Builder builder, org.springframework.web.server.adapter.WebHttpHandlerBuilder httpHandlerBuilder, org.springframework.http.client.reactive.ClientHttpConnector connector) Use methods onWebTestClient.Builder
to modify test client settings.
-
Method Details
-
afterConfigurerAdded
void afterConfigurerAdded(WebTestClient.Builder builder, @Nullable org.springframework.web.server.adapter.WebHttpHandlerBuilder httpHandlerBuilder, @Nullable org.springframework.http.client.reactive.ClientHttpConnector connector) Use methods onWebTestClient.Builder
to modify test client settings. For a mock WebFlux server, useWebHttpHandlerBuilder
to customize server configuration. For a MockMvc server, mutate theMockMvcHttpConnector
and set it onWebTestClient.Builder
.- Parameters:
builder
- the WebTestClient builder for test client changeshttpHandlerBuilder
- for mock WebFlux server settingsconnector
- the connector in use
-