use of org.neo4j.causalclustering.discovery.ClientConnectorAddresses.ConnectorUri in project neo4j by neo4j.
the class ClientConnectorAddressesTest method shouldSerializeToString.
@Test
public void shouldSerializeToString() throws Exception {
// given
ClientConnectorAddresses connectorAddresses = new ClientConnectorAddresses(asList(new ConnectorUri(bolt, new AdvertisedSocketAddress("host", 1)), new ConnectorUri(http, new AdvertisedSocketAddress("host", 2)), new ConnectorUri(https, new AdvertisedSocketAddress("host", 3))));
// when
ClientConnectorAddresses out = ClientConnectorAddresses.fromString(connectorAddresses.toString());
// then
assertEquals(connectorAddresses, out);
}
use of org.neo4j.causalclustering.discovery.ClientConnectorAddresses.ConnectorUri in project neo4j by neo4j.
the class ClientConnectorAddressesTest method shouldSerializeWithNoHttpsAddress.
@Test
public void shouldSerializeWithNoHttpsAddress() throws Exception {
// given
ClientConnectorAddresses connectorAddresses = new ClientConnectorAddresses(asList(new ConnectorUri(bolt, new AdvertisedSocketAddress("host", 1)), new ConnectorUri(http, new AdvertisedSocketAddress("host", 2))));
// when
ClientConnectorAddresses out = ClientConnectorAddresses.fromString(connectorAddresses.toString());
// then
assertEquals(connectorAddresses, out);
}
Aggregations