ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: Support for JUnit 4?
Date Thu, 23 Feb 2006 05:08:35 GMT
On Wed, 22 Feb 2006, Joe Schmetzer <joe@exubero.com> wrote:
> On Wed, 22 February, 2006 11:59 am, Steve Loughran wrote:
>> Having looked at the junit4, I dont see the point in the annotated
>> design.
>>
>> by backing away from having a base class, they have to jump through
>> lots of hoops to make everything work, hoops they have only
>> themselves to blame.
> 
> Without claiming to understand the considerations that went into the
> design of JUnit4, I get the feeling that it is a response to TestNG,
> which relies entirely upon annotations for tagging test methods.

I beg to differ.  TestNG and JUnit 4 are both responses to NUnit 2. 8-)

Given that Kent Beck is quoted on the NUnit page, praising the
"idiomatic design", I'd say JUnit 4 is just adapting this idiomatic
design to Java 5.

I've been using NUnit quite a lot and like the annotations way to do
things.

[Ignore("would currently fail because of the changes if foo")]
public void SomeTest() ...

says so much more than

public void XtestSomeTest() ...

You could easily embed tests in production code and thus easily test
private methods (I've never done so, though).

Categories are nice, platform is nice as well (a test marked up with
Platform("Net-2.0") will be ignored on a 1.1 framework).  I don't know
whether JUnit 4 supports them, though.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message