ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Greg Irvine" <>
Subject "catching" test failure/error (or more generally failure within <subant> calls)
Date Mon, 24 Sep 2007 22:40:51 GMT
I would like to fail our build on junit test failure and still produce the
junit report.

Easy enough generally, however, our build runs somewhat similarly to make in
that I have an ant properties file in each folder that describes the list of
folders to build within that folder, and using common imported generic build
files, it recurses through folders until it finds a project and does a build
(<javac>, <jar>, <junit>, etc).
Once all folders have been recursed through the top level build.xml produces
the report.

The problem I have is that because the <junit> call is done within each
project (eventually, via a tree of nested <subant> calls) if I use the
haltonfailure/haltonerror attributes of <junit> the build fails within the
nested build file and never returns to the top level build file to produce
the report.

Any suggestions?



Ps. The reason I've nested things like this is because there may be projects
in the folder structure I don't want in the main build (for one reason or
another), so I use the properties to specify which subfolders to build
throughout the full structure.
Perhaps if I shifted the lists of folders a single list/file at the top
level I could remove the <subant> nesting and just have a top level file...
hmm... any other suggestions welcome...

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message