AventReporter

ExtentAventReporter is a rich-HTML reporter available from the professional ExtentReports library. This section outlines a few unique features present.

var extent = new ExtentReports();
var avent = new ExtentAventReporter("Avent.html");
extent.AttachReporter(avent);

Configuration

You can apply custom configuration to each reporter using XML, JSON or C#.

C#

var avent = new ExtentAventReporter("avent.html");
avent.Config.Theme = Theme.DARK;
avent.Config.DocumentTitle = "MyReport";

XML

<?xml version="1.0" encoding="UTF-8"?>
<extentreports>
  <configuration>

    <!-- report theme -->
    <!-- STANDARD, DARK -->
    <theme>STANDARD</theme>

    <!-- document encoding -->
    <!-- defaults to UTF-8 -->
    <encoding>UTF-8</encoding>

    <!-- protocol for script and stylesheets -->
    <!-- defaults to https -->
    <!-- HTTP, HTTPS -->
    <protocol>HTTPS</protocol>

    <!-- offline report -->
    <timelineEnabled>true</timelineEnabled>
    
    <!-- offline report -->
    <enableOfflineMode>false</enableOfflineMode>

    <!-- title of the document -->
    <documentTitle>Extent Framework</documentTitle>

    <!-- report name - displayed at top-nav -->
    <reportName>Build 1</reportName>

    <!-- timestamp format -->
    <timeStampFormat>MMM dd, yyyy HH:mm:ss</timeStampFormat>

    <!-- custom javascript -->
    <scripts>
      <![CDATA[
        $(document).ready(function() {
            
        });
      ]]>
    </scripts>

    <!-- custom styles -->
    <styles>
      <![CDATA[
      
      ]]>
    </styles>

  </configuration>
</extentreports>
var avent = new ExtentAventReporter("Avent.html");
avent.LoadXMLConfig("config/avent-config.xml");

JSON

Version 4 and earlier had the ability to consume configuration-XML files, a functionality that remained unchanged in v5.0. External configuration can now be loaded via JSON also, as demonstrated below:

{
  "theme": "STANDARD",
  "encoding": "utf-8",
  "protocol": "HTTPS",
  "timelineEnabled": false,
  "offlineMode": true,
  "documentTitle": "ExtentReports",
  "reportName": "ExtentReports",
  "timeStampFormat": "MMM dd, yyyy HH:mm:ss a",
  "js": "",
  "css": ""
}
var avent = new ExtentAventReporter("Avent.html");
avent.LoadJSONConfig("config/avent-config.json");

Anchors

Test anchors can be used to quickly navigate to any given test from a uri component. An anchor will be generated for each test by default and will appear to the right of the test's timestamp.

To navigate to the test using the anchor, simply add the uri component at the end of the report path:

http://path/to/index.html#test-id=2

Shortcuts

Navigation

t - test
c - tag
d - dashboard
x - exception/bug

Filters

p - show passed tests
f - show failed tests
s - show skipped tests
w - show warning tests
esc - clear filters

Scroll

down-arrow - scroll down
up-arrow - scroll up

Misc

l - switch theme