ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jgl...@apache.org
Subject svn commit: r944361 - /ant/core/trunk/build.xml
Date Fri, 14 May 2010 17:58:43 GMT
Author: jglick
Date: Fri May 14 17:58:43 2010
New Revision: 944361

URL: http://svn.apache.org/viewvc?rev=944361&view=rev
Log:
Distinguishing between compile-time and runtime classpath for JUnit tests.

Modified:
    ant/core/trunk/build.xml

Modified: ant/core/trunk/build.xml
URL: http://svn.apache.org/viewvc/ant/core/trunk/build.xml?rev=944361&r1=944360&r2=944361&view=diff
==============================================================================
--- ant/core/trunk/build.xml (original)
+++ ant/core/trunk/build.xml Fri May 14 17:58:43 2010
@@ -125,6 +125,10 @@
 
   <path id="tests-classpath">
     <pathelement location="${build.classes}"/>
+    <path refid="classpath"/>
+  </path>
+  <path id="tests-runtime-classpath">
+    <path refid="tests-classpath"/>
     <pathelement location="${build.tests}"/>
     <!--
         include the test source and test data dirs
@@ -132,13 +136,8 @@
      -->
     <pathelement location="${src.junit}"/>
     <pathelement location="${tests.etc.dir}"/>
-    <path refid="classpath"/>
   </path>
 
-  <!-- turn this path into a string which is passed to the tests -->
-  <property name="tests-classpath.value"
-    refid="tests-classpath"/>
-
   <!--
         ===================================================================
           Set up properties for the distribution area
@@ -1539,13 +1538,13 @@ see ${build.junit.reports} / ${antunit.r
           <sysproperty key="build.tests.value" value="${build.tests.value}"/>
           <sysproperty key="offline" value="${offline}"/>
           <sysproperty key="tests-classpath.value"
-                       value="${tests-classpath.value}"/>
+                       value="${toString:tests-runtime-classpath}"/>
           <sysproperty key="root" file="${basedir}"/>
           <sysproperty key="build.compiler" value="${build.compiler}"/>
           <sysproperty key="tests.and.ant.share.classloader"
                        value="${tests.and.ant.share.classloader}"/>
           <classpath>
-            <path refid="tests-classpath"/>
+            <path refid="tests-runtime-classpath"/>
             <pathelement location="${junit.collector.dir}"/>
             <!-- FIXME: remove failure collector build code for the moment
                  <path refid="failure.cp"/> 
@@ -1581,7 +1580,7 @@ see ${build.junit.reports} / ${antunit.r
     </condition>
 
     <condition property="junit.testcase" value="${testcase}">
-      <available classname="${testcase}" classpathref="tests-classpath" />
+      <available classname="${testcase}" classpathref="tests-runtime-classpath" />
     </condition>
 
     <fail>Cannot locate test ${testcase}
@@ -1797,7 +1796,7 @@ see ${build.junit.reports} / ${antunit.r
   <target name="interactive-tests" description="--> runs interactive tests"
     depends="compile-tests"
     >
-    <java classpathref="tests-classpath"
+    <java classpathref="tests-runtime-classpath"
       classname="org.apache.tools.ant.taskdefs.TestProcess"
       fork="true"/>
   </target>



Mime
View raw message