@@ -92,7 +92,6 @@ public class RouterFunctionMockMvcBuilder extends AbstractMockMvcBuilder<RouterF
92
92
@ Nullable
93
93
private PathPatternParser patternParser ;
94
94
95
-
96
95
private Supplier <RouterFunctionMapping > handlerMappingFactory = RouterFunctionMapping ::new ;
97
96
98
97
@@ -151,9 +150,8 @@ public RouterFunctionMockMvcBuilder setHandlerExceptionResolvers(HandlerExceptio
151
150
}
152
151
153
152
/**
154
- * Configure factory to create a custom {@link RequestMappingHandlerMapping}.
153
+ * Configure the factory to create a custom {@link RequestMappingHandlerMapping}.
155
154
* @param factory the factory
156
- * @since 5.0
157
155
*/
158
156
public RouterFunctionMockMvcBuilder setCustomHandlerMapping (Supplier <RouterFunctionMapping > factory ) {
159
157
this .handlerMappingFactory = factory ;
@@ -162,27 +160,30 @@ public RouterFunctionMockMvcBuilder setCustomHandlerMapping(Supplier<RouterFunct
162
160
163
161
/**
164
162
* Set up view resolution with the given {@link ViewResolver ViewResolvers}.
165
- * If not set, an {@link InternalResourceViewResolver} is used by default.
163
+ * <p> If not set, an {@link InternalResourceViewResolver} is used by default.
166
164
*/
167
165
public RouterFunctionMockMvcBuilder setViewResolvers (ViewResolver ...resolvers ) {
168
166
this .viewResolvers = Arrays .asList (resolvers );
169
167
return this ;
170
168
}
171
169
172
170
/**
173
- * Sets up a single {@link ViewResolver} that always returns the provided
174
- * view instance. This is a convenient shortcut if you need to use one
175
- * View instance only -- e.g. rendering generated content (JSON, XML, Atom).
171
+ * Set up a single {@link ViewResolver} that always returns the provided
172
+ * view instance.
173
+ * <p>This is a convenient shortcut if you need to use one {@link View}
174
+ * instance only — for example, rendering generated content (JSON, XML,
175
+ * Atom).
176
176
*/
177
177
public RouterFunctionMockMvcBuilder setSingleView (View view ) {
178
178
this .viewResolvers = Collections .<ViewResolver >singletonList (new StaticViewResolver (view ));
179
179
return this ;
180
180
}
181
181
182
182
/**
183
- * Specify the timeout value for async execution. In Spring MVC Test, this
184
- * value is used to determine how to long to wait for async execution to
185
- * complete so that a test can verify the results synchronously.
183
+ * Specify the timeout value for async execution.
184
+ * <p>In Spring MVC Test, this value is used to determine how long to wait
185
+ * for async execution to complete so that a test can verify the results
186
+ * synchronously.
186
187
* @param timeout the timeout value in milliseconds
187
188
*/
188
189
public RouterFunctionMockMvcBuilder setAsyncRequestTimeout (long timeout ) {
@@ -195,7 +196,6 @@ public RouterFunctionMockMvcBuilder setAsyncRequestTimeout(long timeout) {
195
196
* {@link org.springframework.web.util.pattern.PathPattern PathPatterns}
196
197
* instead of String pattern matching with a {@link org.springframework.util.PathMatcher}.
197
198
* @param parser the parser to use
198
- * @since 5.3
199
199
*/
200
200
public RouterFunctionMockMvcBuilder setPatternParser (@ Nullable PathPatternParser parser ) {
201
201
this .patternParser = parser ;
0 commit comments