[Part-4] Running Postman Collection through newman-reporter-htmlextra

In Part-1: We have configured postman collection to run through newman. 
https://testingeduindia.blogspot.com/2020/07/running-postman-collections-through.html

I have tried a tool to generate html report after running the tests through newman using newman-reporter-htmlextra

This was developed by Danny Dainton. 

A HTML reporter for Postman's Command Line Runner, Newman. Includes Non Aggregated Runs broken down by Iterations, Skipped Tests, Console Logs and the handlebars helpers module for better custom templates.

This reporter comes with a dashboard style summary landing page and a set of different tabs which contain the detailed request information. There are also a few optional configuration flags available, to tailor the final report in a number of different ways.

Installation Steps:
In the command prompt, run the below command.
npm install -g newman-reporter-htmlextra
This is to install newman-reporter-htmlextra package globally.

Then navigate to folder containing APITesting Collection.


In order to enable this reporter, we need to specify htmlextra in Newman's -r or --reporters option. 


Run below command: newman run collection.json -r htmlextra




This will create a new folder called as "newman" and report is created in newman folder in html format.




When we open the html report file, it displays the newman run report in dashboard style. 

We can click on Menus to access report based on All Requests, Failed Tests, Skipped Tests.

We can expand the requests and see complete information in single page.


This report can be shared with others and we can store for future testing use.

You can try out different CLI Options as part of newman-reporter-htmlextra.



Note: 
Do not use "IE Edge to open the report, as there are few bugs related to CSS"



Follow Danny Dainton on Twitter: https://twitter.com/DannyDainton

Popular Posts

JMeter Producing Error: Windows RegCreateKeyEx(...) returned error code 5

Understanding about Contract Testing