### Question:
ModulesYamlConfigLoader implements ModulesConfigLoader { @Override public String loadStringOrDefault(String moduleName, String property, String defaultValue) { JsonNode propertyNode = loadPropertyNode(moduleName, property); if (propertyNode == null || propertyNode.isNull()) { return defaultValue; } return propertyNode.asText(); } ModulesYamlConfigLoader();  ModulesYamlConfigLoader(String modulesDirPath); @Override String loadString(String moduleName, String property); @Override String loadStringOrDefault(String moduleName, String property, String defaultValue); @Override Integer loadInteger(String moduleName, String property); @Override Integer loadIntegerOrDefault(String moduleName, String property, Integer defaultValue); @Override List<String> loadStringList(String moduleName, String property); @Override List<String> loadStringListOrDefault(String moduleName, String property, List<String> defaultValue); @Override List<Integer> loadIntegerList(String moduleName, String property); @Override List<Integer> loadIntegerListOrDefault(String moduleName, String property, List<Integer> defaultValue);  }### Answer:
@Test public void testLoadStringPropertyReturnsValueIfFound() { String defaultValue = "DEFAULT"; String value = loader.loadStringOrDefault(CONFIG_FILE, "string", defaultValue); assertThat(value).isEqualTo("John Doe"); }
@Test public void testLoadStringPropertyReturnsDefaultIfNotFound() { String defaultValue = "DEFAULT"; String value = loader.loadStringOrDefault(CONFIG_FILE, NOT_EXISTING_PROPERTY, defaultValue); assertThat(value).isEqualTo(defaultValue); }
@Test public void testLoadStringPropertyReturnsDefaultIfNullValueFound() { String defaultValue = "DEFAULT"; String value = loader.loadStringOrDefault(CONFIG_FILE, NULL_PROPERTY, defaultValue); assertThat(value).isEqualTo(defaultValue); }