assertAnnounced();
}
private void assertAnnounced(ServiceAnnouncement... serviceAnnouncements)
{
ServiceDescriptors serviceDescriptors = discoveryClient.getServices(serviceType.value(), "pool").checkedGet();
assertEquals(serviceDescriptors.getType(), serviceType.value());
assertEquals(serviceDescriptors.getPool(), "pool");
assertNotNull(serviceDescriptors.getETag());
assertEquals(serviceDescriptors.getMaxAge(), MAX_AGE);
List<ServiceDescriptor> descriptors = serviceDescriptors.getServiceDescriptors();
assertEquals(descriptors.size(), serviceAnnouncements.length);
ImmutableMap.Builder<UUID, ServiceDescriptor> builder = ImmutableMap.builder();
for (ServiceDescriptor descriptor : descriptors) {
builder.put(descriptor.getId(), descriptor);