InMemoryRegistryRepository implements RegistryRepository { @Override public Registry get(final String registryName) { return registry.get(registryName); }  @Override void createOrUpdate(Registry registry); @Override void delete(final String name); @Override Set<String> getKnownNames(); @Override Registry get(final String registryName); @Override void clear(); final ConcurrentMap<String, Registry> registry; }
@Test public void shouldReturnNullForNotExistingLinks() { final RegistryRepository registries = new InMemoryRegistryRepository(); final Registry registry = registries.get("does not exist"); assertNull(registry); }