On Wed, 22 February, 2006 2:00 pm, Steve Loughran wrote: > Joe Schmetzer wrote: >> 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.
[snip Steve's insightful list of issues with JUnit4] > It is certainly a response to TestNG, with some eclipse hooks in there > by the look of things. I just dont think they should have followed > testNG so aggressively. I think I agree there. Although there are some JUnit4 has raised a lot of doubt in developers minds as to how to use the new annotations. Although JUnit4 can still work with the JUnit3 style of test declaration, it must be compiled and run under a 1.5 jdk, which will exclude a large number of people who have not yet upgraded their infrastructure. Personally, I like that fact that unit tests written independantly of TestCase, but I don't think I can use the new features yet, as I'm not really willing to cut all ties with pre-1.5 environments. >> I think the whole point of this change is to reduce coupling between >> test methods and the test infrastructure (TestCase, Assert and >> friends). > > Assert has always been decoupled; you can extend or use it anywhere. True, but in practice I've only ever seen it used as inheried methods from TestCase. I expect that this will change, now. > What they now have in the JAR is two separate Assert classes, > junit.Assert and org.junit.Assert, with duplicate code. Me, I'd have > moved everything to the new org.junit.Assert and made junit.Assert a > facade, not a complete duplicate. Ewwww.... copy and paste programming! :-) I just had a look at the differences between junit.framework.Assert and org.junit.Assert. There are actually a large number of differences (along with a lot of similarities). Not only has the code been copied, but they are diverging in terms of behaviour. How confusing! -- Joe Schmetzer .:. Renaissance Developer .:. http://www.exubero.com/blog/ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]