From aa44b0b3b29a30bf56efa40d72cd6229189ba635 Mon Sep 17 00:00:00 2001 From: Robert Muir Date: Wed, 19 Sep 2012 12:26:15 +0000 Subject: [PATCH] LUCENE-4397: speed up test git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1387548 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/lucene/index/TestIndexWriterWithThreads.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lucene/core/src/test/org/apache/lucene/index/TestIndexWriterWithThreads.java b/lucene/core/src/test/org/apache/lucene/index/TestIndexWriterWithThreads.java index 004e7464530..356fadcf794 100644 --- a/lucene/core/src/test/org/apache/lucene/index/TestIndexWriterWithThreads.java +++ b/lucene/core/src/test/org/apache/lucene/index/TestIndexWriterWithThreads.java @@ -513,7 +513,7 @@ public class TestIndexWriterWithThreads extends LuceneTestCase { // LUCENE-4147 public void testRollbackAndCommitWithThreads() throws Exception { - final BaseDirectoryWrapper d = newFSDirectory(_TestUtil.getTempDir("RollbackAndCommitWithThreads")); + final BaseDirectoryWrapper d = newDirectory(); if (d instanceof MockDirectoryWrapper) { ((MockDirectoryWrapper)d).setPreventDoubleWrite(false); } @@ -524,7 +524,7 @@ public class TestIndexWriterWithThreads extends LuceneTestCase { writerRef.set(new IndexWriter(d, newIndexWriterConfig(TEST_VERSION_CURRENT, new MockAnalyzer(random())))); final LineFileDocs docs = new LineFileDocs(random()); final Thread[] threads = new Thread[threadCount]; - final int iters = atLeast(1000); + final int iters = atLeast(100); final AtomicBoolean failed = new AtomicBoolean(); final Lock rollbackLock = new ReentrantLock(); final Lock commitLock = new ReentrantLock();