GH-2366 Fix failing test on Mac
Resolves https://github.com/spring-projects/spring-integration/issues/2366
This commit is contained in:
committed by
Gary Russell
parent
24809557fb
commit
4397807a57
@@ -316,7 +316,20 @@ public class ConnectionEventTests {
|
||||
|
||||
@Test
|
||||
public void testFailConnect() {
|
||||
TcpNetClientConnectionFactory ccf = new TcpNetClientConnectionFactory("junkjunk", 1234);
|
||||
AbstractClientConnectionFactory ccf = new AbstractClientConnectionFactory("junkjunk", 1234) {
|
||||
|
||||
@Override
|
||||
protected boolean isActive() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected TcpConnectionSupport buildNewConnection() throws Exception {
|
||||
throw new UnknownHostException("Mocking for test ");
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
final AtomicReference<ApplicationEvent> failEvent = new AtomicReference<ApplicationEvent>();
|
||||
ccf.setApplicationEventPublisher(new ApplicationEventPublisher() {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user