Complete initialization with bindToRouterFunction
Issue: SPR-17239
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2017 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -50,7 +50,10 @@ class DefaultRouterFunctionSpec extends AbstractMockServerSpec<WebTestClient.Rou
|
||||
@Override
|
||||
protected WebHttpHandlerBuilder initHttpHandlerBuilder() {
|
||||
WebHandler webHandler = RouterFunctions.toWebHandler(this.routerFunction, this.handlerStrategies);
|
||||
return WebHttpHandlerBuilder.webHandler(webHandler);
|
||||
return WebHttpHandlerBuilder.webHandler(webHandler)
|
||||
.filters(filters -> filters.addAll(this.handlerStrategies.webFilters()))
|
||||
.exceptionHandlers(handlers -> handlers.addAll(this.handlerStrategies.exceptionHandlers()))
|
||||
.localeContextResolver(this.handlerStrategies.localeContextResolver());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user