2

I want to create test reports (reports generated after the execution of each test case). I can generate JUnit test reports using ANT. But, my requirement is such that I would have to generate these reports through Java.

Which is the best way to create test reports using Java ?

The test reports need not only be created in JUnit. It can be created in any test framework. Any suggestions / advice related to it might prove helpful. So, request you to share you experience in generating test reports using Java.

2 Answers 2

1

TestNG reports get generate automaticlly if you run a suite(xml). Standard folder is test-output in your project. Have a look at the testNG doc at chapter 6.2.2 and following http://testng.org/doc/documentation-main.html how to customize those.

0

TestNG provides a programmatic way to run the tests without using any build file. TestNG suite and other parameters that are being used in build XML have corresponding JAVA classes. Check this link. http://testng.org/doc/documentation-main.html#running-testng-programmatically

You can get the report as mentioned by Tarken.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.