Fix Sporadic Test Failure

https://build.spring.io/browse/INT-MJATS41-925/
This commit is contained in:
Gary Russell
2017-03-03 09:49:42 -05:00
parent 4ada89d0c6
commit 099ab8a6ae

View File

@@ -16,6 +16,7 @@
package org.springframework.integration.ip.tcp.connection;
import static org.hamcrest.CoreMatchers.anyOf;
import static org.hamcrest.CoreMatchers.containsString;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
@@ -486,7 +487,9 @@ Certificate fingerprints:
}
catch (IOException e) {
if (!(e instanceof ClosedChannelException)) {
assertThat(e.getMessage(), containsString("Socket closed during SSL Handshake"));
assertThat(e.getMessage(), anyOf(
containsString("Socket closed during SSL Handshake"),
containsString("Broken pipe")));
}
}
}