Apache Solr open-source search software
less simpletext, less simplefsdir, put directdv in rotation
Robert Muir673c2bde4583
diff --git a/lucene/test-framework/src/java/org/apache/lucene/index/RandomCodec.java b/lucene/test-framework/src/java/org/apache/lucene/index/RandomCodec.javaindex 095e39b37b7..fd94dc2b2c6 100644--- a/lucene/test-framework/src/java/org/apache/lucene/index/RandomCodec.java+++ b/lucene/test-framework/src/java/org/apache/lucene/index/RandomCodec.java@@ -37,6 +37,7 @@ import org.apache.lucene.codecs.blockterms.LuceneVarGapDocFreqInterval;import org.apache.lucene.codecs.blockterms.LuceneVarGapFixedInterval;import org.apache.lucene.codecs.blocktreeords.BlockTreeOrdsPostingsFormat;import org.apache.lucene.codecs.bloom.TestBloomFilteredLucenePostings;+import org.apache.lucene.codecs.memory.DirectDocValuesFormat;import org.apache.lucene.codecs.memory.DirectPostingsFormat;import org.apache.lucene.codecs.memory.FSTOrdPostingsFormat;import org.apache.lucene.codecs.memory.FSTPostingsFormat;@@ -136,15 +137,16 @@ public class RandomCodec extends AssertingCodec {new LuceneFixedGap(TestUtil.nextInt(random, 1, 1000)),new LuceneVarGapFixedInterval(TestUtil.nextInt(random, 1, 1000)),new LuceneVarGapDocFreqInterval(TestUtil.nextInt(random, 1, 100), TestUtil.nextInt(random, 1, 1000)),- new SimpleTextPostingsFormat(),+ random.nextInt(10) == 0 ? new SimpleTextPostingsFormat() : TestUtil.getDefaultPostingsFormat(),new AssertingPostingsFormat(),new MemoryPostingsFormat(true, random.nextFloat()),new MemoryPostingsFormat(false, random.nextFloat()));addDocValues(avoidCodecs,TestUtil.getDefaultDocValuesFormat(),+ new DirectDocValuesFormat(), // maybe not a great idea...new MemoryDocValuesFormat(),- new SimpleTextDocValuesFormat(),+ random.nextInt(10) == 0 ? new SimpleTextDocValuesFormat() : TestUtil.getDefaultDocValuesFormat(),new AssertingDocValuesFormat());Collections.shuffle(formats, random);diff --git a/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.java b/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.javaindex deff9a6d642..f581522f88b 100644--- a/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.java+++ b/lucene/test-framework/src/java/org/apache/lucene/util/LuceneTestCase.java@@ -1291,6 +1291,10 @@ public abstract class LuceneTestCase extends Assert {String fsdirClass = TEST_DIRECTORY;if (fsdirClass.equals("random")) {fsdirClass = RandomPicks.randomFrom(random(), FS_DIRECTORIES);+ if (fsdirClass.equals("SimpleFSDirectory")) {+ // pick again+ fsdirClass = RandomPicks.randomFrom(random(), FS_DIRECTORIES);+ }}Class<? extends FSDirectory> clazz;@@ -1517,6 +1521,10 @@ public abstract class LuceneTestCase extends Assert {if (clazzName.equals("random")) {if (rarely(random)) {clazzName = RandomPicks.randomFrom(random, CORE_DIRECTORIES);+ if (clazzName.equals("SimpleFSDirectory")) {+ // pick again+ clazzName = RandomPicks.randomFrom(random, CORE_DIRECTORIES);+ }} else {clazzName = "RAMDirectory";}