LUCENE-8233: Use a consistent merge policy in test to make sure segment counts match

This commit is contained in:
Simon Willnauer 2018-04-05 12:23:41 +02:00
parent 60ae7be407
commit 4a902f35db
1 changed files with 1 additions and 1 deletions

View File

@ -159,7 +159,7 @@ public class TestSoftDeletesRetentionMergePolicy extends LuceneTestCase {
IndexWriterConfig indexWriterConfig = newIndexWriterConfig(); IndexWriterConfig indexWriterConfig = newIndexWriterConfig();
indexWriterConfig.setMergePolicy(new SoftDeletesRetentionMergePolicy("soft_delete", indexWriterConfig.setMergePolicy(new SoftDeletesRetentionMergePolicy("soft_delete",
() -> new MatchAllDocsQuery(), () -> new MatchAllDocsQuery(),
indexWriterConfig.getMergePolicy())); new LogDocMergePolicy()));
indexWriterConfig.setSoftDeletesField("soft_delete"); indexWriterConfig.setSoftDeletesField("soft_delete");
IndexWriter writer = new IndexWriter(dir, indexWriterConfig); IndexWriter writer = new IndexWriter(dir, indexWriterConfig);