Allure is a framework/tool which generates comprehensive reports for your test executions. This happens in two steps:
- The test results are captured and written to xml files
- The xml files are transformed into beautiful reports
Please consult the Allure website to obtain further information about Allure.
The Allure module acts as an adapter between tapir’s Notification API and Allure’s Reporting API. If the optional module is in the classpath at test runtime, the corresponding xml files are generated. These xml files are picked up by Allure and transformed to a good-looking report.
<dependency> <groupId>de.bmiag.tapir</groupId> <artifactId>tapir-allure</artifactId> </dependency>
The screenshot below displays a sample test execution report.
In general you can just use this command:
> mvn clean test allure:serve
Maven fires up a web server and starts the browser which renders the Allure report.
Allure provides a plugin for Jenkins. Please consult the documentation on their website, but in general the defaults are fine to work with tapir.
The Allure Report is stored for every build and you can switch from the Jenkins UI to the Allure report and vice versa.