Cedric Beust is the creator of Test NG which he wrote in response to his experiences using JUnit. He also is now a Googler which shows that a different way to work for them is invent something cool, useful and scalable.
When I first read the Test NG site, I didn’t see what was so cool that you would want to migrate away from the tried-and-true JUnit, but after this I think it is certainly worth exploring if you are running Java 5 or greater. I think if you are using Java 4 still that it would be worth just sticking with Junit as he admits that it is kinda sketchy in that environment.
There was a lot of stuff that would be of interest to developers (or testers who have a more java-centric slant than I have), but as an influencer, I found the following interesting.
- JUnit’s design forces test independence (by re-instantiating the test class each run
- This forces certain design consideration
- Are you testing or are you junit testing your code
- Annotations are cool – closest thing we have in Python 2.x is Decorators but Annotations are coming in Python 3.
- Only available in Java — so in theory one could use this with jython. Very interesting
- There is a built-in junit mode for ease of conversion
- Cedric has a book coming out – Next Generation Java Testing: TestNG and Advanced Concepts
- There is work on a distributed Test NG where slave machines take independent tests and collate the results – very metaframework-ish
Direct link here.