@Test
public void testRegister() {

    Set<URL> registered;
    for (int i = 0; i < 2; i++) {
        consulRegistry.register(serviceUrl);
        registered = consulRegistry.getRegistered();
        assertThat(registered.contains(serviceUrl), is(true));
    }
    registered = consulRegistry.getRegistered();
    assertThat(registered.size(), is(1));
}