fix false test failure

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1079786 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael McCandless 2011-03-09 13:25:14 +00:00
parent 82c22128be
commit 907d4c708f
2 changed files with 3 additions and 3 deletions

View File

@ -518,7 +518,7 @@ final class DocumentsWriter {
if (segmentInfos.size() > 0 || newSegment != null) {
final FrozenBufferedDeletes packet = new FrozenBufferedDeletes(pendingDeletes, delGen);
if (infoStream != null) {
message("flush: push buffered deletes");
message("flush: push buffered deletes startSize=" + pendingDeletes.bytesUsed.get() + " frozenSize=" + packet.bytesUsed);
}
bufferedDeletesStream.push(packet);
if (infoStream != null) {

View File

@ -2549,7 +2549,7 @@ public class TestIndexWriter extends LuceneTestCase {
final Random r = random;
Directory dir = newDirectory();
FlushCountingIndexWriter w = new FlushCountingIndexWriter(dir, newIndexWriterConfig( TEST_VERSION_CURRENT, new MockAnalyzer(MockTokenizer.WHITESPACE, true, false)).setRAMBufferSizeMB(0.5).setMaxBufferedDocs(-1).setMaxBufferedDeleteTerms(-1));
FlushCountingIndexWriter w = new FlushCountingIndexWriter(dir, newIndexWriterConfig( TEST_VERSION_CURRENT, new MockAnalyzer(MockTokenizer.WHITESPACE, true, false)).setRAMBufferSizeMB(1.0).setMaxBufferedDocs(-1).setMaxBufferedDeleteTerms(-1));
w.setInfoStream(VERBOSE ? System.out : null);
Document doc = new Document();
doc.add(newField("field", "go 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20", Field.Store.NO, Field.Index.ANALYZED));
@ -2576,7 +2576,7 @@ public class TestIndexWriter extends LuceneTestCase {
count++;
}
}
assertTrue("flush happened too quickly during " + (doIndexing ? "indexing" : "deleting") + " count=" + count, count > 1500);
assertTrue("flush happened too quickly during " + (doIndexing ? "indexing" : "deleting") + " count=" + count, count > 3000);
}
w.close();
dir.close();