JUnit5 Listener that generates an HTML test report using the Extent reporting framework.
If you run your tests programmatically you may use the class directly as an argument when launching tests via
the org.junit.platform.launcher.Launcher
final LauncherDiscoveryRequestBuilder builder = LauncherDiscoveryRequestBuilder.request();
builder.selectors(selectPackage("com.example.test"));
final ExtentReportGeneratingListener extentReportGeneratingListener = new ExtentReportGeneratingListener();
LauncherFactory.create().execute(builder.build(), extentReportGeneratingListener);Create a file org.junit.platform.launcher.TestExecutionListener in the path src/main/resources/META-INF/services/
and enter the fully qualified name of the class you want to load in that file:
io.github.gdiegel.junit5_html_report_generator.ExtentReportGeneratingListener
The Java ServiceLoader will automatically load the report generator. In any case the report will be generated
as report.html in the project root.