tests: fix leak of test harness

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1022730 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Yonik Seeley 2010-10-14 21:36:21 +00:00
parent c7720b369c
commit 62ef53cdd0
1 changed files with 5 additions and 4 deletions

View File

@ -48,15 +48,16 @@ public class TestArbitraryIndexDir extends AbstractSolrTestCase{
public void setUp() throws Exception {
super.setUp();
dataDir = new File(TEMP_DIR,
getClass().getName() + "-" + System.currentTimeMillis() + System.getProperty("file.separator") + "solr"
+ System.getProperty("file.separator") + "data");
dataDir.mkdirs();
solrConfig = h.createConfig(getSolrConfigFile());
solrConfig = h.createConfig("solrconfig.xml");
h = new TestHarness( dataDir.getAbsolutePath(),
solrConfig,
getSchemaFile());
"schema12.xml");
lrf = h.getRequestFactory
("standard",0,20,"version","2.2");
}
@ -68,12 +69,12 @@ public class TestArbitraryIndexDir extends AbstractSolrTestCase{
@Override
public String getSchemaFile() {
return "schema12.xml";
return null;
}
@Override
public String getSolrConfigFile() {
return "solrconfig.xml";
return null; // prevent superclass from creating it's own TestHarness
}
@Test