*
The moose likes Testing and the fly likes Taking Report for junit Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » Testing
Bookmark "Taking Report for junit" Watch "Taking Report for junit" New topic
Author

Taking Report for junit

A Kumar
Ranch Hand

Joined: Jul 04, 2004
Posts: 979
how to generate reports using junit..

if i run a test for one class..
i want see it in eclipse ..IDE..the resulsts...but how to capture it as a report...
Jan Cumps
Bartender

Joined: Dec 20, 2006
Posts: 2491
    
    8

One posibility is to use Ant.
You can use Ant's JUnit and JUnitReport tasks to create a html report for your tests.

Regards, Jan


OCUP UML fundamental and ITIL foundation
youtube channel
A Kumar
Ranch Hand

Joined: Jul 04, 2004
Posts: 979
And how to generate it without Ant ...??
Jan Cumps
Bartender

Joined: Dec 20, 2006
Posts: 2491
    
    8

Maven also allows you to create a report of your JUnit tests.
I am not aware of any other solution.

Regards, Jan
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30074
    
149

If you just want the failures (as opposed to a pretty report with all the tests), you could use the text runner that comes with JUnit and store the output.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
A Kumar
Ranch Hand

Joined: Jul 04, 2004
Posts: 979
Thanks everyone....

I am able to created junit reports using ant build script
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Taking Report for junit
 
Similar Threads
Customizing Ant /JUnit XML Output
junit
junit test report eclipse?
How to creat a report from JUnit
Not able to generate Junit Report