TestNG 5.0 Released

| by Floyd Marinescu Follow 30 Followers on Jul 20, 2006. Estimated reading time: less than one minute |

A note to our readers: You asked so we have developed a set of features that allow you to reduce the noise: you can get email and web notifications for topics you are interested in. Learn more about our new features.

Cedric Beust has announced the launch of TestNG, the popular Testing framework and alternative to JUnit.  Alexandru Popescu (TestNG co-founder) is also InfoQ's Chief Architect.  Cedric blogged about the announcement and provided insights into the new features and why they were added.

The major new features in TestNG are:
  • Configuration annotations are now called @BeforeTest, @BeforeSuite, which are terse and also support IDE auto-completion for users who might type @Before
  • When executing multiple test suites, reports are now kept distinct in each suite's directory. Report UI's have also been improved.
  • New SuiteName and testName attributes in the @Test annotation allows grouping tests to specific suites in the code instead of TestNG.XML. Useful for grouping reports for tests executed via ant or command line.
  • @ExpectedAnnotations deprecated in favour of an expectedExceptions attribute in @Test.
  • Improved StackTrace readibility by hiding unnecessary portions of the stack trace
TestNG was started by Cedric Beust out of frustration for some JUnit deficiencies which he has documented  here, here, here and in particular, here.  TestNG has become popular over the years due to it's improvements over JUnit, culminating in JUnit 4.0's replication of some TestNG features.

Rate this Article

Adoption Stage

Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Revamped annotations and more by Alex Popescu

The new TestNG 5.0 version introduces a completely revamped set of annotations that are meant to make things more clear and the tests extremely readable. Considering, also the reporting improvements and also the new features of the TestNG Ant task, I would say that TestNG 5.0 is one of the most important versions in its history.

.w( the_mindstorm )p.

Re: Revamped annotations and more by Floyd Marinescu

Congragulations guys!

Re: Revamped annotations and more by BK Lau


Congrats!. I want to say that now that TestNG is gaining traction, my suggestion in minor release would be really nice to put some efforts to "buff" up reporting. The current out-of-box reporting is an improvement but... from my experience management are mesmerized by reports and those nice html presentations, maybe DHTML/AJAX.
I kid you not..that's what managers look at.(Read: Stats and something they can present in meetings....)
TestNG needs to have a "signature" reporting that caused "wow!"s and not let Junit pretty reporting take the lead.
Keep up with the good job.


Re: Revamped annotations and more by Alex Popescu

BK we are open to any suggestions. So, come on the TestNG mailing list and tell us how can we improve the reports, so that they become shiny ;-).

.w( the_mindstorm )p.

Re: Revamped annotations and more by Cedric Beust


No argument there, I know how important presentation is, but unfortunately, I'm pretty bad at design. I'm still hoping that someone with some decent HTML/CSS/DHTML sense will come in and beef up our HTML reports...


Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

5 Discuss

Login to InfoQ to interact with what matters most to you.

Recover your password...


Follow your favorite topics and editors

Quick overview of most important highlights in the industry and on the site.


More signal, less noise

Build your own feed by choosing topics you want to read about and editors you want to hear from.


Stay up-to-date

Set up your notifications and don't miss out on content that matters to you