### Question:
FileGroupReader { static Map<String, String> loadContents(Path rootDir) throws IOException { try (Stream<Path> walk = Files.walk(rootDir, 1)) { return walk.filter(path -> !Files.isDirectory(path)) .collect(Collectors.toMap(FileGroupReader::asString, FileGroupReader::readContents)); } } FileGroupReader(String pathToGroup);   }### Answer:
@Test public void loadFilesFromMemory() throws IOException { fileSystem.defineFile("group/a.b", "1234"); fileSystem.defineFile("group/x/c.d", "5678"); Path p = fileSystem.getPath("group"); Map<String, String> map = FileGroupReader.loadContents(p); assertThat(map, hasEntry("group/a.b", "1234")); assertThat(map, hasEntry("group/x/c.d", "5678")); }