Fix rare test failure.

This test fails when the maximum segment size is only one byte larger
than the min segment size.
This commit is contained in:
Adrien Grand 2020-10-05 09:58:18 +02:00
parent 34776ed640
commit 1038fe8bee
1 changed files with 1 additions and 1 deletions

View File

@ -71,7 +71,7 @@ public class TestSizeBoundedForceMerge extends LuceneTestCase {
conf = newWriterConfig();
LogByteSizeMergePolicy lmp = new LogByteSizeMergePolicy();
lmp.setMaxMergeMBForForcedMerge((min + 1) / (1 << 20));
lmp.setMaxMergeMBForForcedMerge(min / (1 << 20));
conf.setMergePolicy(lmp);
writer = new IndexWriter(dir, conf);