mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
Consistent IOException spelling in class/method names
This commit is contained in:
+1
-1
@@ -29,7 +29,7 @@ public class ExceptionController {
|
||||
|
||||
// tag::narrow[]
|
||||
@ExceptionHandler({FileSystemException.class, RemoteException.class})
|
||||
public ResponseEntity<String> handleIoException(IOException ex) {
|
||||
public ResponseEntity<String> handleIOException(IOException ex) {
|
||||
return ResponseEntity.internalServerError().body(ex.getMessage());
|
||||
}
|
||||
// end::narrow[]
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ class ExceptionController {
|
||||
|
||||
// tag::narrow[]
|
||||
@ExceptionHandler(FileSystemException::class, RemoteException::class)
|
||||
fun handleIoException(ex: IOException): ResponseEntity<String> {
|
||||
fun handleIOException(ex: IOException): ResponseEntity<String> {
|
||||
return ResponseEntity.internalServerError().body(ex.message)
|
||||
}
|
||||
// end::narrow[]
|
||||
|
||||
+1
-1
@@ -149,7 +149,7 @@ class RestTemplateObservationTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
void executeWithIoExceptionAddsUnknownOutcome() throws Exception {
|
||||
void executeWithIOExceptionAddsUnknownOutcome() throws Exception {
|
||||
String url = "https://example.org/resource";
|
||||
mockSentRequest(GET, url);
|
||||
given(request.execute()).willThrow(new IOException("Socket failure"));
|
||||
|
||||
+2
-2
@@ -172,7 +172,7 @@ class ExceptionHandlerExceptionResolverTests {
|
||||
@Test
|
||||
void resolveNoExceptionHandlerForException() throws NoSuchMethodException {
|
||||
Exception npe = new NullPointerException();
|
||||
HandlerMethod handlerMethod = new HandlerMethod(new IoExceptionController(), "handle");
|
||||
HandlerMethod handlerMethod = new HandlerMethod(new IOExceptionController(), "handle");
|
||||
this.resolver.afterPropertiesSet();
|
||||
ModelAndView mav = this.resolver.resolveException(this.request, this.response, handlerMethod, npe);
|
||||
|
||||
@@ -540,7 +540,7 @@ class ExceptionHandlerExceptionResolverTests {
|
||||
|
||||
|
||||
@Controller
|
||||
static class IoExceptionController {
|
||||
static class IOExceptionController {
|
||||
|
||||
public void handle() {}
|
||||
|
||||
|
||||
+1
-1
@@ -240,7 +240,7 @@ class SockJsSessionTests extends AbstractSockJsSessionTests<TestSockJsSession> {
|
||||
}
|
||||
|
||||
@Test
|
||||
void writeFrameIoException() throws Exception {
|
||||
void writeFrameIOException() throws Exception {
|
||||
this.session.setExceptionOnWrite(new IOException());
|
||||
this.session.delegateConnectionEstablished();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user