Example Code

Converting TestStand ATML Reports to JUnit

Code and Documents



TestStand ATML reports can be converted to other formats using eXtensible Stylesheet Language Transformations (XSLT). This can be useful for importing Test Results into a tool that is not compatible with the TestStand ATML Test Result schema.


 This example takes an ATML 6.0.1 report and converts it to a JUnit report format compatible with the Jenkins JUnit plugin. This allows users to view step results in Jenkins:

Note: This example stylesheet only converts basic test result data into JUnit - such as Step Name and Step Status. This stylesheet can be modified to include additional failure information for specific step types.

Hardware and Software Requirements

NI TestStand

Command Line Transformation Utility (msxsl.exe)

Steps to Implement or Execute Code

  1. Download the attached stylesheet and msxsl.exe from Microsoft.
  2. Generate a TestStand ATML Report using the report plugin.
  3. Run the following command in the Windows command prompt:
    msxsl <path to test report> <path to example stylesheet> -o <path to output xml file>

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.