Polish: simplify ControllerMethodResolver initialization

This commit is contained in:
Rossen Stoyanchev
2018-05-15 10:45:03 -04:00
parent 7424ca5790
commit 18854ee544
4 changed files with 98 additions and 150 deletions

View File

@@ -76,7 +76,7 @@ public class ControllerMethodResolverTests {
applicationContext.refresh();
this.methodResolver = new ControllerMethodResolver(
resolvers, codecs.getReaders(), ReactiveAdapterRegistry.getSharedInstance(), applicationContext);
resolvers, ReactiveAdapterRegistry.getSharedInstance(), applicationContext, codecs.getReaders());
Method method = ResolvableMethod.on(TestController.class).mockCall(TestController::handle).method();
this.handlerMethod = new HandlerMethod(new TestController(), method);

View File

@@ -79,7 +79,7 @@ public class ModelInitializerTests {
resolverConfigurer.addCustomResolver(new ModelArgumentResolver(adapterRegistry));
ControllerMethodResolver methodResolver = new ControllerMethodResolver(
resolverConfigurer, Collections.emptyList(), adapterRegistry, new StaticApplicationContext());
resolverConfigurer, adapterRegistry, new StaticApplicationContext(), Collections.emptyList());
this.modelInitializer = new ModelInitializer(methodResolver, adapterRegistry);
}