You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-commits@db.apache.org by dj...@apache.org on 2007/03/30 23:15:51 UTC

svn commit: r524273 - /db/derby/code/trunk/build.xml

Author: djd
Date: Fri Mar 30 14:15:50 2007
New Revision: 524273

URL: http://svn.apache.org/viewvc?view=rev&rev=524273
Log:
Add logic to build.xml so that the build fails for target junitreport if the tests fail.
This allows better integration with tools like CruiseControl that can report automatically upon failures.

Modified:
    db/derby/code/trunk/build.xml

Modified: db/derby/code/trunk/build.xml
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/build.xml?view=diff&rev=524273&r1=524272&r2=524273
==============================================================================
--- db/derby/code/trunk/build.xml (original)
+++ db/derby/code/trunk/build.xml Fri Mar 30 14:15:50 2007
@@ -1686,7 +1686,9 @@
            fork="yes" forkmode="once"
            jvm="${derby.junit.jvm}"
            showoutput="yes"
-           dir="junit_${derby.junit.timestamp}/testout">
+           dir="junit_${derby.junit.timestamp}/testout"
+  	 	   errorproperty="tests.failed"
+  	       failureproperty="tests.failed">
       <formatter type="xml"/>
       <test name="${derby.junit.testname}" 
             todir="junit_${derby.junit.timestamp}"/>
@@ -1783,6 +1785,8 @@
           out="junit_${derby.junit.timestamp}/overview-frame2.html"/>
     <move file="junit_${derby.junit.timestamp}/overview-frame2.html"
           tofile="junit_${derby.junit.timestamp}/overview-frame.html"/>
+  	
+  	<fail if="tests.failed">Tests Failed!</fail>
   </target>
 
   <target name="l10ncheck"> 
@@ -1796,7 +1800,7 @@
 	-->
 	<target name="junit-all-codeline-jars" depends="setsanityname">
 		<property name="derby.jar.base" value="${basedir}/jars/${sanity.name}"/>
-	    <antcall target="junit-all">
+	    <antcall target="junitreport">
 	      <param name="derby.junit.classpath"
 	        value="${derby.jar.base}/derbyTesting.jar:${derby.jar.base}/derbynet.jar:${derby.jar.base}/derbytools.jar:${derby.jar.base}/derbyclient.jar"/>
 	    </antcall>