use of org.neo4j.causalclustering.core.state.CoreState in project neo4j by neo4j.
the class ConnectionInfoIT method catchupServerMessage.
@Test
public void catchupServerMessage() throws Throwable {
// given
testSocket = bindPort("localhost", 4242);
// when
AssertableLogProvider logProvider = new AssertableLogProvider();
AssertableLogProvider userLogProvider = new AssertableLogProvider();
CoreState coreState = mock(CoreState.class);
Config config = Config.defaults().with(singletonMap(transaction_listen_address.name(), ":" + testSocket.getLocalPort()));
CatchupServer catchupServer = new CatchupServer(logProvider, userLogProvider, mockSupplier(), mockSupplier(), mockSupplier(), mockSupplier(), mock(BooleanSupplier.class), coreState, config, new Monitors(), mockSupplier(), mock(FileSystemAbstraction.class), mock(PageCache.class), new StoreCopyCheckPointMutex());
//then
try {
catchupServer.start();
} catch (Throwable throwable) {
//expected.
}
logProvider.assertContainsMessageContaining("Address is already bound for setting");
userLogProvider.assertContainsMessageContaining("Address is already bound for setting");
}
Aggregations