Monday, January 21, 2019

Post 1: Generate Results Report In Selenium with ExtentReports Version 4

ExtentReports V4 has been released and it is more beautiful and interactive. In this post we will discuss about generating the reports using Extentreports V4 in Selenium with TestNG.

Step 1: Create a Maven project and add the required dependencies in the pom.xml file as shown below

Step 2: Create a base class, where we will initialize the ExtentReports and configure extent report with the theme and title. Also add system information as shown below

In the we have instantiated and configured the ExtentReports in the @BeforeClass method so that it will be executed once before executing all the demo tests.

And in @AfterClass method we are closing the extent report, this method will be executed after executing all the demo tests.

Step 3: Create a demo tests class and write some test case, in the below example we wrote 4 test cases (2 Pass, 1 Fail, 1 Skip)

Execute the test cases and open the ExtentReports.html file, which is defined The results should be looking as below

Results View:

Dashboard View:

System Info:

Thanks for reading. #HappyLearning #HappyTesting

1 comment:

  1. Such a very useful article. Very interesting to read this article.I would like to thank you for the efforts you had made for writing this awesome article. investire alle canarie con rendita garantita


DevOps 01: What is DevOps and How it benefits organizations?

DevOps is a culture in an organization, where the development team and operations team help each other by sharing information, process and t...