Skip to content

Commit

Permalink
Ignore lock file when testing cleanupAndPreserveLatestCommitPoint (op…
Browse files Browse the repository at this point in the history
…ensearch-project#4544)

Signed-off-by: Daniel Widdis <[email protected]>

Signed-off-by: Daniel Widdis <[email protected]>
(cherry picked from commit 7ebb2af)
  • Loading branch information
dbwiddis authored and mch2 committed Nov 10, 2022
1 parent 083890f commit 563c34b
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1189,8 +1189,10 @@ public void testCleanupAndPreserveLatestCommitPoint() throws IOException {

// we want to ensure commitMetadata files are preserved after calling cleanup
for (String existingFile : store.directory().listAll()) {
assertTrue(commitMetadata.contains(existingFile));
assertFalse(additionalSegments.contains(existingFile));
if (!IndexWriter.WRITE_LOCK_NAME.equals(existingFile)) {
assertTrue(commitMetadata.contains(existingFile));
assertFalse(additionalSegments.contains(existingFile));
}
}
deleteContent(store.directory());
IOUtils.close(store);
Expand Down

0 comments on commit 563c34b

Please sign in to comment.