jenkins the definitive guide

(Jeff_L) #1

Figure 6.2. Configuring Maven test reports in a freestyle project


For Java projects, whether they are using JUnit or TestNG, Jenkins does an excellent job out of the box.
If you are using Jenkins for non-Java projects, you might need the xUnit Plugin. This plugin lets Jenkins
process test reports from non-Java tools in a consistent way. It provides support for MSUnit and NUnit
(for C# and other .NET languages), UnitTest++ and Boost Test (for C++), PHPUnit (for PHP), as well
as a few other xUnit libraries via additional plugins (see Figure 6.3, “Installing the xUnit plugin”).


Figure 6.3. Installing the xUnit plugin


Once you have installed the xUnit Plugin, you will need to configure the reporting for your particular
xUnit reports in the “Post-build Actions” section. Check the “Publish testing tools result report”
checkbox, and enter the path to the XML reports generated by your testing library (see Figure 6.4,
“Publishing xUnit test results”). When the build job runs, Jenkins will convert these reports to JUnit
reports so that they can be displayed in Jenkins.

Free download pdf