### Question:
FileJournalManager implements JournalManager { public static List<EditLogFile> matchEditLogs(File logDir) throws IOException { return matchEditLogs(FileUtil.listFiles(logDir)); } FileJournalManager(StorageDirectory sd,
      StorageErrorReporter errorReporter); @Override void close(); @Override void format(NamespaceInfo ns); @Override boolean hasSomeData(); @Override synchronized EditLogOutputStream startLogSegment(long txid); @Override synchronized void finalizeLogSegment(long firstTxId, long lastTxId); @VisibleForTesting StorageDirectory getStorageDirectory(); @Override synchronized void setOutputBufferCapacity(int size); @Override void purgeLogsOlderThan(long minTxIdToKeep); List<RemoteEditLog> getRemoteEditLogs(long firstTxId); static List<EditLogFile> matchEditLogs(File logDir); @Override synchronized void selectInputStreams(
      Collection<EditLogInputStream> streams, long fromTxId,
      boolean inProgressOk); @Override synchronized void recoverUnfinalizedSegments(); List<EditLogFile> getLogFiles(long fromTxId); EditLogFile getLogFile(long startTxId); static EditLogFile getLogFile(File dir, long startTxId); @Override String toString();  }### Answer:
@Test(expected = IOException.class) public void testMatchEditLogInvalidDirThrowsIOException() throws IOException { File badDir = new File("does not exist"); FileJournalManager.matchEditLogs(badDir); }