Author: ltheussl Date: Tue Nov 7 04:50:26 2006 New Revision: 472091 URL: http://svn.apache.org/viewvc?view=rev&rev=472091 Log: PR: MPTEST-71 New property maven.test.haltafterfailure to halt a build on test failures but after all tests have been run.
Modified: maven/maven-1/plugins/trunk/test/plugin.jelly maven/maven-1/plugins/trunk/test/plugin.properties maven/maven-1/plugins/trunk/test/xdocs/changes.xml maven/maven-1/plugins/trunk/test/xdocs/properties.xml Modified: maven/maven-1/plugins/trunk/test/plugin.jelly URL: http://svn.apache.org/viewvc/maven/maven-1/plugins/trunk/test/plugin.jelly?view=diff&rev=472091&r1=472090&r2=472091 ============================================================================== --- maven/maven-1/plugins/trunk/test/plugin.jelly (original) +++ maven/maven-1/plugins/trunk/test/plugin.jelly Tue Nov 7 04:50:26 2006 @@ -211,6 +211,9 @@ <j:set var="_testfailure" value="${maven.test.failure}"/> <j:if test="${_testfailure}"> + <j:if test="${context.getVariable('maven.test.haltafterfailure') != 'false'}"> + <ant:fail>There were test failures!</ant:fail> + </j:if> <echo> ========================================================== @@ -353,6 +356,9 @@ <j:set var="_testfailure" value="${maven.test.failure}"/> <j:if test="${_testfailure}"> + <j:if test="${context.getVariable('maven.test.haltafterfailure') != 'false'}"> + <ant:fail>There were test failures!</ant:fail> + </j:if> <echo> ========================================================== @@ -482,6 +488,9 @@ <j:set var="_testfailure" value="${maven.test.failure}"/> <j:if test="${_testfailure}"> + <j:if test="${context.getVariable('maven.test.haltafterfailure') != 'false'}"> + <ant:fail>There were test failures!</ant:fail> + </j:if> <echo> ========================================================== Modified: maven/maven-1/plugins/trunk/test/plugin.properties URL: http://svn.apache.org/viewvc/maven/maven-1/plugins/trunk/test/plugin.properties?view=diff&rev=472091&r1=472090&r2=472091 ============================================================================== --- maven/maven-1/plugins/trunk/test/plugin.properties (original) +++ maven/maven-1/plugins/trunk/test/plugin.properties Tue Nov 7 04:50:26 2006 @@ -36,6 +36,7 @@ maven.test.skip = false maven.test.excludeXmlApis = no maven.test.classpath = +maven.test.haltafterfailure=false maven.test.compile.compilerargs = ${maven.compile.compilerargs} maven.test.compile.encoding = ${maven.compile.encoding} Modified: maven/maven-1/plugins/trunk/test/xdocs/changes.xml URL: http://svn.apache.org/viewvc/maven/maven-1/plugins/trunk/test/xdocs/changes.xml?view=diff&rev=472091&r1=472090&r2=472091 ============================================================================== --- maven/maven-1/plugins/trunk/test/xdocs/changes.xml (original) +++ maven/maven-1/plugins/trunk/test/xdocs/changes.xml Tue Nov 7 04:50:26 2006 @@ -24,6 +24,7 @@ </properties> <body> <release version="1.8.1-SNAPSHOT" date="In SVN"> + <action dev="ltheussl" type="add" issue="MPTEST-71">New property to halt a build on test failures but after all tests have been run.</action> <action dev="ltheussl" type="add" due-to="Nicolas de Loof" issue="MPTEST-69">New properties to configure compiler for test classes.</action> <action dev="ltheussl" type="fix" due-to="Dennis Lundberg" issue="MPTEST-68">SourceModifications sometimes does not work for test classes.</action> <action dev="ltheussl" type="fix" due-to="Shinobu Kawai" issue="MPTEST-67">maven.compile.target is not used in test:compile.</action> Modified: maven/maven-1/plugins/trunk/test/xdocs/properties.xml URL: http://svn.apache.org/viewvc/maven/maven-1/plugins/trunk/test/xdocs/properties.xml?view=diff&rev=472091&r1=472090&r2=472091 ============================================================================== --- maven/maven-1/plugins/trunk/test/xdocs/properties.xml (original) +++ maven/maven-1/plugins/trunk/test/xdocs/properties.xml Tue Nov 7 04:50:26 2006 @@ -243,6 +243,15 @@ </td> </tr> <tr> + <td>maven.test.haltafterfailure</td> + <td>Yes</td> + <td> + Set this to <code>true</code> to halt the build on any test failures + (note: errors are considered failures as well), but <strong>after</strong> + all tests have been run. Default value is <code>false</code>. + </td> + </tr> + <tr> <td>maven.test.reportsDirectory</td> <td>Yes</td> <td>