1

I am trying to generate the expected HTML report with ReportNG. I have included the necessary jar files (guice, velocity, and reportng) and written a Test class and various Page Object classes. I added the necessary listeners into the testing.xml file. I have coded in Java and used Selenium and TestNG. My tests all run successfully.

My only problem is that the report is not updating. I ran it once with only one test to make sure it works. The report was generated successfully and shows one method was passed. I added 4 other tests and the HTML report still shows only one method. I tried deleting the old HTML report and no new one has generated.

Here is a screenshot of my project

Thanks in advance!

Alex
  • 15
  • 5

2 Answers2

0

Even i tried using ReportNG, but as per my knowledge, ReportNG is no more used, instead I would suggest, use customized TestNG report format.

Here are few links, which may be helpful for you,

https://www.seleniumeasy.com/testng-tutorials/testng-customize-emailable-html-report-example

https://github.com/cbeust/testng/commit/31cc17da840d31682daae6b283c0a8766c93bd13 ---- In here go through the EmailableReporter.java

Ruchi Dhole
  • 95
  • 2
  • 12
  • Are you sure ReportNG not using now ? – Adithya Sep 23 '16 at 04:27
  • yes, when I tried using it didnt work, and on many blogs it was posted saying it is not being used – Ruchi Dhole Sep 26 '16 at 07:15
  • it worked for the first time for me, then the report is not updating. Still showing the result of first run. So Im not using it anymore. http://stackoverflow.com/questions/39654254/how-to-customize-selenium-testng-default-report-or-create-new-html-report/39667775#39667775 – Adithya Sep 27 '16 at 10:23
0

To generate reportNG reports please make sure, default TestNG Listeners is disabled.

It can be done by following the below steps:

  1. Right Click on the project.
  2. Right Click on Properties
  3. Click on TestNG.
  4. You will find an option as "Disable default listeners", check the checbox
  5. Click on "Apply" button, it will show as message as "Project preferences are saved".
  6. Now Click on "OK" button.
Sharfi
  • 355
  • 4
  • 12