LUCENE-3795: use MockAnalyzer for testing

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1300426 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Muir 2012-03-14 00:31:28 +00:00
parent 0c447d1344
commit 22b145e43e
2 changed files with 3 additions and 4 deletions

View File

@ -28,7 +28,6 @@
<path id="test.classpath">
<path refid="test.base.classpath" />
<path refid="base.classpath"/>
<pathelement path="${analyzers-common.jar}" />
<pathelement path="src/test-files" />
</path>
@ -36,6 +35,6 @@
<target name="init" depends="contrib-build.init"/>
<target name="dist-maven" depends="jar-core,javadocs,common.dist-maven"/>
<target name="compile" depends="jar-queries,common.compile-core" />
<target name="test" depends="jar-analyzers-common,compile-test,validate,junit-mkdir,junit-sequential,junit-parallel" description="Runs unit tests"/>
<target name="test" depends="compile-test,validate,junit-mkdir,junit-sequential,junit-parallel" description="Runs unit tests"/>
</project>

View File

@ -17,7 +17,7 @@
package org.apache.lucene.spatial;
import org.apache.lucene.analysis.core.WhitespaceAnalyzer;
import org.apache.lucene.analysis.MockAnalyzer;
import org.apache.lucene.document.Document;
import org.apache.lucene.index.DirectoryReader;
import org.apache.lucene.index.IndexWriter;
@ -49,7 +49,7 @@ public abstract class SpatialTestCase extends LuceneTestCase {
directory = newDirectory();
IndexWriterConfig writerConfig = newIndexWriterConfig(random, TEST_VERSION_CURRENT, new WhitespaceAnalyzer(TEST_VERSION_CURRENT));
IndexWriterConfig writerConfig = newIndexWriterConfig(random, TEST_VERSION_CURRENT, new MockAnalyzer(random));
indexWriter = new IndexWriter(directory, writerConfig);
}