LUCENE-8714: Don't use NoMergePolicy in norms tests

This can cause spurious failures when run in conjunction with HandleLimitFS,
as we can end up with lots of very small segments which trips the file handles
limit
This commit is contained in:
Alan Woodward 2019-03-01 14:45:05 +00:00
parent 8381b7368d
commit 5ca00c0b64

View File

@ -451,7 +451,7 @@ public abstract class BaseNormsFormatTestCase extends BaseIndexFileFormatTestCas
Directory dir = applyCreatedVersionMajor(newDirectory());
Analyzer analyzer = new MockAnalyzer(random(), MockTokenizer.WHITESPACE, false);
IndexWriterConfig conf = newIndexWriterConfig(analyzer).setMergePolicy(NoMergePolicy.INSTANCE);
IndexWriterConfig conf = newIndexWriterConfig(analyzer);
CannedNormSimilarity sim = new CannedNormSimilarity(norms);
conf.setSimilarity(sim);
RandomIndexWriter writer = new RandomIndexWriter(random(), dir, conf);