### Question:
InputJarArchive extends JarArchive implements ReadableArchive { @Override public Collection<String> getDirectories() throws IOException { return new CollectionWrappedEnumeration<String>( new CollectionWrappedEnumeration.EnumerationFactory<String>() { @Override public Enumeration<String> enumeration() { return entries(true); } }); }  long getArchiveSize(); OutputStream addEntry(String name); synchronized void close(); @Override Collection<String> getDirectories(); void create(URI uri); @Override Enumeration<String> entries(); Enumeration entries(Enumeration embeddedArchives); JarEntry getJarEntry(String name); boolean exists(String name); InputStream getEntry(String entryName); long getEntrySize(String name); void open(URI uri); Manifest getManifest(); URI getURI(); boolean exists(); boolean delete(); boolean renameTo(String name); ReadableArchive getSubArchive(String name); static final Logger deplLogger; }### Answer:
@Test public void testTopLevelDirEntryNamesForInputJarArchive() { try { System.out.println("top-level directory entry names in InputJarArchive"); final ReadableArchive arch = getArchiveForTest(); final Set<String> returnedNames = new HashSet<String>(arch.getDirectories()); assertEquals("Returned top-level directories do not match expected", testJarTopLevelDirEntryNames(), returnedNames); retireArchive(arch); } catch (IOException ex) { ex.printStackTrace(System.out); fail("Error during test"); } }