Skip to content

Apache Lucene open-source search software

Rename tempDir to workDir in Junit4 Macro, as suggested in ML thread.

Uwe Schindlera2864cdcb09a
diff --git a/lucene/build.xml b/lucene/build.xml
index e61d8d13eec..71dd7305ad9 100644
--- a/lucene/build.xml
+++ b/lucene/build.xml
@@ -133,7 +133,7 @@
-->
<test-macro
dataDir="${backwards.dir}/core/src/test"
- tempDir="${build.dir.backwards}/test"
+ workDir="${build.dir.backwards}/test"
junit.classpath="backwards.junit.classpath"
junit.output.dir="${junit.output.dir.backwards}"
tests.nightly="false"
diff --git a/lucene/common-build.xml b/lucene/common-build.xml
index 92ed0f4a287..215978aba7d 100644
--- a/lucene/common-build.xml
+++ b/lucene/common-build.xml
@@ -113,7 +113,7 @@
<property name="tests.heapdump.args" value=""/>
- <property name="tests.tempDir" location="${build.dir}/test"/>
+ <property name="tests.workDir" location="${build.dir}/test"/>
<property name="tests.cachefile" location="${common.dir}/tools/junit4/cached-timehints.txt" />
<property name="tests.cachefilehistory" value="20" />
@@ -760,7 +760,7 @@
<attribute name="junit.output.dir" default="${junit.output.dir}"/>
<attribute name="junit.classpath" default="junit.classpath"/>
<attribute name="testsDir" default="${build.dir}/classes/test"/>
- <attribute name="tempDir" default="${tests.tempDir}"/>
+ <attribute name="workDir" default="${tests.workDir}"/>
<attribute name="threadNum" default="1"/>
<attribute name="tests.nightly" default="${tests.nightly}"/>
<attribute name="tests.weekly" default="${tests.weekly}"/>
@@ -817,11 +817,12 @@
-->
</junit4:pickfromlist>
- <mkdir dir="@{tempDir}/temp" />
+ <!-- junit4 does not create this directory. TODO: is this a bug / inconsistency with dir="..."? -->
+ <mkdir dir="@{workDir}/temp" />
<junit4:junit4
- dir="@{tempDir}"
- tempdir="@{tempDir}/temp"
+ dir="@{workDir}"
+ tempdir="@{workDir}/temp"
maxmemory="${tests.heapsize}"
parallelism="@{threadNum}"
@@ -895,7 +896,7 @@
<sysproperty key="java.io.tmpdir" value="." />
<!-- Restrict access to certain Java features and install security manager: -->
- <sysproperty key="junit4.tempDir" file="@{tempDir}/temp" />
+ <sysproperty key="junit4.tempDir" file="@{workDir}/temp" />
<sysproperty key="clover.db.dir" file="${clover.db.dir}" />
<sysproperty key="java.security.manager" value="org.apache.lucene.util.TestSecurityManager" />
<sysproperty key="java.security.policy" file="${common.dir}/tools/junit4/tests.policy" />
@@ -2043,7 +2044,7 @@ The following arguments can be provided to ant to alter its behaviour and target
<junit4:pickseed property="pitest.seed" />
- <property name="pitest.sysprops" value="-Dlucene.version=${dev.version},-Dtest.seed=${pitest.seed},-Djava.security.manager=org.apache.lucene.util.TestSecurityManager,-Djava.security.policy=${common.dir}/tools/junit4/tests.policy,-Djava.io.tmpdir=${tests.tempDir},-Djunit4.childvm.cwd=${tests.tempDir},-Djunit4.tempDir=${tests.tempDir}" />
+ <property name="pitest.sysprops" value="-Dlucene.version=${dev.version},-Dtest.seed=${pitest.seed},-Djava.security.manager=org.apache.lucene.util.TestSecurityManager,-Djava.security.policy=${common.dir}/tools/junit4/tests.policy,-Djava.io.tmpdir=${tests.workDir},-Djunit4.childvm.cwd=${tests.workDir},-Djunit4.tempDir=${tests.workDir}" />
<pitest
classPath="pitest.classpath"