ApolloRepository implements ConfigurationRepository { @Override public String get(final String key) { String value = configWrapper.getProperty(pathToKey(key)); return Strings.isNullOrEmpty(value) ? openApiWrapper.getValue(pathToKey(key)) : value; }  @Override void init(final String name, final GovernanceCenterConfiguration config); @Override String get(final String key); @Override List<String> getChildrenKeys(final String key); @Override void persist(final String key, final String value); @Override void delete(final String key); @Override void watch(final String key, final DataChangedEventListener dataChangedEventListener); @Override void close(); @Override String getType();  }
@Test public void assertGet() { assertThat(REPOSITORY.get("/test/children/0"), is("value0")); }
@Test public void assertGetByOpenApi() { assertNull(REPOSITORY.get("/test/children/6")); }
@Test public void assertGetWithNonExistentKey() { assertNull(REPOSITORY.get("/test/nonExistentKey")); }
@Test public void assertWatchUpdateChangedTypeWithExistedKey() throws InterruptedException, ExecutionException, TimeoutException { assertWatchUpdateChangedType("/test/children/4", "test.children.4", "newValue4"); assertThat(REPOSITORY.get("/test/children/4"), is("newValue4")); }