void verifyIgnoringFiles(Cache cache0, Cache cache1, Set<String> files) { verifyIgnoringFiles(cache0, files); verifyIgnoringFiles(cache1, files); }
@Test @Override public void testIndexWritingAndFinding() throws IOException, InterruptedException { verifyIgnoringFiles(cache0, cache1, Util.asSet("pending_segments_1")); IndexOutput indexOutput = dirA.createOutput(filename, IOContext.DEFAULT); indexOutput.writeString("no need to write, nobody ever will read this"); dirB.close(); Set<String> left_behind = Util.asSet("pending_segments_1", "readme.txt"); verifyIgnoringFiles(cache0, left_behind); verifyIgnoringFiles(cache1, left_behind);