### Question:
JsonConfigLoaderStrategy extends AbstractConfigLoader { @Override public Map<String, Object> readConfiguration(InputStream inputStream) { TypeReference<Map<String, Object>> token = new TypeReference<Map<String, Object>>() { }; try { return mapper.readValue(inputStream, token); } catch (Exception e) { throw new RuntimeException(e); } } JsonConfigLoaderStrategy(InputStream inputStream, String rootDirectory);  JsonConfigLoaderStrategy(String configContent, String rootDirectory);  JsonConfigLoaderStrategy(String configContent); @Override Map<String, Object> readConfiguration(InputStream inputStream);  }### Answer:
@Test public void jacksonConfigClassLoader() throws IOException { Path filePath = Paths.get(TestUtils.getTestResourcePath(), "configs/loader", "yamlConfigLoaderTest.json"); JsonConfigLoaderStrategy jsonConfigLoaderStrategy = new JsonConfigLoaderStrategy(new FileInputStream(filePath.toString()), TestUtils.getTestResourcePath()); Map<String, Object> map = jsonConfigLoaderStrategy.readConfiguration(); configLoaderAssert(map); }
@Test public void yamlConfigClassLoader() throws IOException { Path filePath = Paths.get(TestUtils.getTestResourcePath(), "configs/loader", "yamlConfigLoaderTest.yaml"); YamlConfigLoaderStrategy jsonConfigLoaderStrategy = new YamlConfigLoaderStrategy(new FileInputStream(filePath.toString()), TestUtils.getTestResourcePath()); Map<String, Object> map = jsonConfigLoaderStrategy.readConfiguration(); configLoaderAssert(map); }