Rutger Lubbers wrote:
Hi,
JUnit (since 4.?) allows filtering of the tests to be run. It would be
nice to allow ant build scripts to use this filter capacity. This would
allow developers to run a (small, fast running) set of tests, while the
integration or production build runs extra test sets. The filtering only
works with JUnit 4 test code.
I've changed a few source files (of ant 1.7.0) and added two. It works
fine (here). It requires (at the moment) a typedef of the filter:
<typedef name="junitfilter"
classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitFilter"/>
and can be used as follows:
<junit>
<junitfilter
classname="com.example.JUnitDBFilter"
properties="dbtest"/>
</junit>
I would like to know if you find this useful (enough) for inclusion.
Would someone like to see the code and comment on it?
Thanks & Kind regards,
JUnit4 stuff is something I'd like to work on, either as a separate
antlib or as somethig in Ant, presumably in the package
org.apache.tools.ant.taskdefs.optional.junit4
1. I was planning a new task for it, one that is a superset of <junit>;
this filtering could go in there.
2. I'm planning to extend the xml test results to include more data
(from junit4, antunit, and anything else compatible)
-add skipped tests: count+details
-allow every test to have a description, a URL and a bugID (well, a
list of them)
-dump more machine details into a per-machine file when we do the
test run;
I think the filter stuff could go in there; why not add it as an
enhancement request (with code) to bugzilla under issues.apache.org?
-steve
--
Steve Loughran http://www.1060.org/blogxter/publish/5
Author: Ant in Action http://antbook.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]