File tree 1 file changed +4
-5
lines changed
spring-web/src/test/java/org/springframework/web/context/request/async
1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -162,11 +162,10 @@ void startCallableProcessingDisconnectedClient() throws Exception {
162
162
AsyncEvent event = new AsyncEvent (new MockAsyncContext (this .servletRequest , this .servletResponse ), ex );
163
163
this .asyncWebRequest .onError (event );
164
164
165
- MockAsyncContext asyncContext = (MockAsyncContext ) this .servletRequest .getAsyncContext ();
166
165
assertThat (this .asyncManager .hasConcurrentResult ()).isTrue ();
167
166
assertThat (this .asyncManager .getConcurrentResult ())
168
- .as ("Disconnected client error not wrapped AsyncRequestNotUsableException" )
169
- .isOfAnyClassIn (AsyncRequestNotUsableException .class );
167
+ .as ("Disconnected client error not wrapped in AsyncRequestNotUsableException" )
168
+ .isExactlyInstanceOf (AsyncRequestNotUsableException .class );
170
169
}
171
170
172
171
@ Test
@@ -287,8 +286,8 @@ void startDeferredResultProcessingDisconnectedClient() throws Exception {
287
286
288
287
assertThat (this .asyncManager .hasConcurrentResult ()).isTrue ();
289
288
assertThat (deferredResult .getResult ())
290
- .as ("Disconnected client error not wrapped AsyncRequestNotUsableException" )
291
- .isOfAnyClassIn (AsyncRequestNotUsableException .class );
289
+ .as ("Disconnected client error not wrapped in AsyncRequestNotUsableException" )
290
+ .isExactlyInstanceOf (AsyncRequestNotUsableException .class );
292
291
}
293
292
294
293
You can’t perform that action at this time.
0 commit comments