Icon

You are viewing the documentation of TeamCity 9.x, which is not the most recently released version of TeamCity.
View this page in TeamCity 10.x documentation or refer to the listing to choose the documentation corresponding to your TeamCity version.

 
Skip to end of metadata
Go to start of metadata

The XML Report processing build feature allows using report files produced by an external tool in TeamCity. TeamCity will parse the specified files on the disk and report the results as the build results.

The report parsing can also be initiated from within the build via service messages.

XML Report Processing supports the following testing frameworks:

  • JUnit Ant task
  • Maven Surefire/Failsafe plugin
  • NUnit-Console XML reports
  • TRX reports (for MSTest 2005/2008/2010/2012/2013/2015 and VSTest 2012/2013/2015)
  • Google Test XML reports
  • XML output from CTest

and the following code inspection tools:

  • FindBugs (code inspections only): only FindBugs native format is supported (see a sample). The XML report generated by the FindBugs Maven Plugin is NOT supported: it has completely different schema layout and elements.
  • PMD
  • Checkstyle
  • JSLint XML reports

and the following code duplicates tools:

  • PMD Copy/Paste Detector XML reports

The bundled XML Report Processing plugin monitors the specified report paths, and when the matching files are detected, they are parsed according to the report type specified. For some report types, parsing of partially saved files is supported, so reporting is started as soon as first data is available and more data is reported as it is written on the disk.

The plugin takes into account only the files updated since the build start (determined by means of the last modification file timestamp).

Configuring XML Report Processing

Add XML Report Processing as a build feature and configure its settings:

  • Choose the report type and specify monitoring rules in the form of +|-:path separating them by a comma or new line.

    Icon

    To be processed, report XML files (or a directory) must be located in the checkout directory, and the path must be relative to this directory.

    Paths without the +|: prefix are treated as including. Ant-style wildcards are supported, e.g. dir/**.xml means all files with the .xml extension under the "dir" directory).

    Icon

    TeamCity loads generated reports once when they are created, make sure your build procedure generates files with unique names for each tests set without overwriting report files.

  • Check the Verbose output option to enable detailed logging to the build log.
  • For FindBugs report processing, it is necessary to specify the path to the FindBugs installation on the agent. It will be used for retrieving actual bug patterns, categories and their messages.
  • For FindBugs, PMD and Checkstyle code inspections reports processing you can specify maximum errors and warnings limits, exceeding which will cause a build failure. Leave these fields blank if there are no limits.

See plugin page at XML Test Reporting.



See also: