continuum-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Julien HENRY <henr...@yahoo.fr>
Subject Re : Build planification ignore/fail on test produce unexpected result
Date Thu, 13 Aug 2009 08:37:17 GMT
Hi Martin,

Thanks for your suggestion.

If I understand the failsafe plugin documentation and your suggestion, it means failing the
build during the verify phase instead of test phase.

So I will try something like:
1)
configure failsafe plugin to be attached to the test phase instead of
the integration-test one
2) disable surefire
3) mvn clean post-integration-test site site-deploy sonar:sonar install verify

Anyway I can already tell I don't like this solution as it smells too much a hack for me and
it will make it harder for my users to understand the purpose of all this mess.
What a pity there is no separate verify goal on the surefire plugin...

++

Julien




________________________________
De : Martin Höller <martin@xss.co.at>
À : users@continuum.apache.org
Envoyé le : Jeudi, 13 Août 2009, 8h35mn 59s
Objet : Re: Build planification ignore/fail on test produce unexpected result

Hi Julien!

On Wednesday 12 August 2009 Julien HENRY wrote:
> Here is my configuration : I have 2 build definitions
>
> 1) clean install --batch-mode (every hour)
> 2) clean deploy sonar:sonar site site-deploy
> -Dmaven.test.failure.ignore=true --batch-mode (every night)
>
> In one of my project I have some JUnit test failures. Every hour, if
> there are svn modifications, build one will start and fail then send
> notifications. In Continuum UI the color of the project is orange or red.
>
> Now I did a manual run of build two (because I didn't wanted to wait next
> day but I'm curious to see if build two will run if there is no svn
> modification since last time build one run). Build two obviously succeed
> as test failure are ignored and site was generated. But my concern is
> that in Continuum UI, project color is GREEN ! And worst, build one will
> never be started again until there are svn modifications.
>
> I don't know what would be the perfect solution, but I propose to clearly
> separate build executions and only say a project is green when all build
> definitions are green.

I never had a problem like this, so all my suggestions are just theory...

Eventually the Failsafe Maven Plugin [0] (or at least its concepts) could 
help here. It is designed to run integration tests but i guess one could 
configure it to also run unit tests.

The idea of the plugin is to separate running of the tests and verifying its 
results. You could eventually run the tests (with some failures), produce 
the reports and afterwards verify (in some later phase) the test results 
and fail the build.

hth,
- martin

[0] http://mojo.codehaus.org/failsafe-maven-plugin/



      
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message