AFAIK and as you said, JUnit is designed to complete a test suite even a test 
case is failed. So I think that your request would concern JUnit. Maybe all you 
need is find a way to tell your test suite fails when the first test case fails.

The surefire plug-in is just a classloader to run test and I think the 
<testFailureIgnore> property aims only to tell M2 continue its tasks after the 
test phase and sure fire report can generate report. 

Personally, I'm using M2.0.4 and integrate the sure fire report in the 
generated web site so I need <testFailureIgnore> to be true to have the report 
of failed tests. Moreover, all my tests are executed even some of them fail.

----- Original Message ----
From: Dennis Klavans <[EMAIL PROTECTED]>
To: users@maven.apache.org; [EMAIL PROTECTED]
Sent: Thursday, August 3, 2006 2:06:45 PM
Subject: RE: SureFire (and surefire-reports) plugins


This is odd. I just posted a request for the exact opposite to happen. I can't 
get the thing to stop on the first failure. First, are you running mvn 
surefire-report:report? If so then perhaps we could help each other by 
comparing environments. What version of maven are you using? I am on the 
latest: 2.04.

Also, the property you refered to is actually <testFailureIgnore>. Just wanted 
to confirm that. Still, I did not have that set and mine would not stop. Having 
looked at the surefire source, I cannot see what would make it stop. Perhaps if 
the tests were themselves defined in a suite within the testing framework, that 
suite would fail at the first test? My tests are all individually defined and 
surefire is the controller running them. I am using the JUnit framework and 
JUnit seems to trap the exception from an invididual test so that is why 
surefire keeps going. 




 --- On Thu 08/03, Jon SlinnHawkins < [EMAIL PROTECTED] > wrote:
From: Jon SlinnHawkins [mailto: [EMAIL PROTECTED]
To: users@maven.apache.org
Date: Thu, 3 Aug 2006 09:18:31 +0100
Subject: SureFire (and surefire-reports) plugins

Hi All,<br><br>Is there any way of stop a failed surefire unit from immediatley 
failing a <br>maven build, and allowing it to go on to create the report using 
the <br>surefire-report plugin.  Then, after the reports hasve been created 
fail the <br>build.<br><br>I want to see reports of failed tests....<br><br>Is 
this possible... Can you switch off halt-on-failure for the Surefire 
<br>plugin, and switch it on for the report plugin ?<br><br>Thanks<br><br>Jon 
<br><br><br><br><br>---------------------------------------------------------------------<br>To
 unsubscribe, e-mail: [EMAIL PROTECTED]<br>For additional commands, e-mail: 
[EMAIL PROTECTED]<br><br>

_______________________________________________
Join Excite! - http://www.excite.com
The most personalized portal on the Web!



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





Reply via email to