Apache Lucene open-source search software
enable Test2BPostings only @Nightly and not with Memory nor SimpleText codec
Michael McCandless94a47f44159a
diff --git a/lucene/src/test/org/apache/lucene/index/Test2BPostings.java b/lucene/src/test/org/apache/lucene/index/Test2BPostings.javaindex 82517c04dda..3f919cb5574 100644--- a/lucene/src/test/org/apache/lucene/index/Test2BPostings.java+++ b/lucene/src/test/org/apache/lucene/index/Test2BPostings.java@@ -24,10 +24,10 @@ import org.apache.lucene.analysis.TokenStream;import org.apache.lucene.analysis.tokenattributes.CharTermAttribute;import org.apache.lucene.document.Document;import org.apache.lucene.document.Field;+import org.apache.lucene.index.codecs.CodecProvider;import org.apache.lucene.store.MockDirectoryWrapper;import org.apache.lucene.util.LuceneTestCase;import org.apache.lucene.util._TestUtil;-import org.junit.Ignore;/**@@ -35,8 +35,13 @@ import org.junit.Ignore;* @lucene.experimental*/public class Test2BPostings extends LuceneTestCase {- @Ignore("Must run with large (14 GB) java heap, and not Memory nor SimpleText codec!")++ @Nightlypublic void test() throws Exception {++ assumeFalse("This test cannot run with Memory codec", CodecProvider.getDefault().getFieldCodec("field").equals("Memory"));+ assumeFalse("This test is super-slow and very disk-space-consuming with SimpleText codec", CodecProvider.getDefault().getFieldCodec("field").equals("SimpleText"));+MockDirectoryWrapper dir = newFSDirectory(_TestUtil.getTempDir("2BPostings"));dir.setThrottling(MockDirectoryWrapper.Throttling.NEVER);dir.setCheckIndexOnClose(false); // don't double-checkindex