Closed shubautomation closed 1 year ago
You can attach any number of reporters to ExtentReports:
var firefoxReport = new ExtentSparkReporter("firefox.html");
var chromeReport = new ExtentSparkReporter("chrome.html");
extent.AttachReporter(firefoxReport, chromeReport);
// somewhere in your hooks (pseudo-code)
if (test.hasTag("firefox")) {
firefoxReport.log();
} else {
chromeReport.log();
}
As you can see, if the number of conditions increase, it can become a little difficult to maintain this structure. It's probably better to use tags and filter them on the UI:
_extent.CreateTest("Test").AssignCategory("firefox");
_extent.CreateTest("Test").AssignCategory("chrome");
Hi Team, @anshooarora @namilkimfree
I want to generate the multiple extent reports for different browsers. For example, in Azure pipeline if I run for Chrome then name of the report should be TestReport_Chrome.html and same fro different browsers.
I am also not able to change the name of the report. It is default to index.html
Can you please suggest me how we can change the name of the report to our customise name?