Definite's Extractor

My findings on Life, Linux, Open Source, and so on.

Generate JUnit XML format for Jenkins from CMake CTest

In JUnit XML Skeleton fits for Hudson., I showed the minimal JUnit XML for showing  meaningful results in Hudson/Jenkins.

But how to generate the JUnit XML from cmake and ctest?

I got the inspiration from How to get CTest results in Hudson / Jenkins in StackOverflow and create following  CTest2JUnit.xsl.

To use the xsl, you may either use the CTest2JUnit.pl I provide in the same directory, or following command in Linux:

xsltproc CTest2JUnit.xsl Testing/`head -n 1 < Testing/TAG`/Test.xml > JUnitTestResults.xml
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: