XmlTest TeamCity plugin
XSpec scenarios in your TeamCity server
XmlTest is a plugin for continuous integration server TeamCity.
It allows you to integrate your XSpec scenarios to your continous integration workflow.
/target/XmlTest.zipto your TeamCity server plugins folder (under your TeamCity Data folder), e.g.
C:\TeamCityData\plugins\XmlTestshould contain subfolders
serverand one file
- Restart TeamCity server and all build agents
Build configuration with XmlTest
XmlTest installs as a build runner. So you need to
- Create a project in TeamCity as you would normally do (you can use SampleXSpecProject in this repo to test it)
- Create a new build step in your configuration.
- Pick XmlTest as runner type
- Enter paths to your xspec scenarios. Wildcards are recognized, so you might want to use something like
- Go to general settings of your build configuration and add the following lines to the
target\xmltest-xspec-results/**/*.xml => xspec.zip target\xmltest-xspec-results/**/*.html => xspec.zip
- Go to your Project settings (not build configuration settings) and in Report tabs, add a new tab titled
XSpecwith Start page
- You are now ready to run your build!
Once your build is finished, you can examine the results in
- Overview tab (build results)
- Tests tab (each scenario ~ one line)
- XSpec tab shows reports produced by XSpec formatter (part of the XSpec project)
- Artifacts tab - here you can download the reports in XML or HTM (as produced by the formatter)
- Build log - displays output of the XSLT processor running the scenarios.
XmlTest runs XProc pipeline for each .xspec file. The pipeline applies a series of transformation on the .xspec file and produces an XML report. This report is then again formatted by an XSLT stylesheet, which produces an HTML report.
If you wish, you can peek at the code doing all this in
TeamCity\buildAgent\plugins\XmlTest-agent\runtime\xproc\compiler folder (and make any modification you like). Or fork the repo and make your changes in XmlTest-agent/src/runtime/xproc.
To compile the plugin yourself, run
mvn package in the root, which will produce
XSpec is a behavior driven development framework for your XSLT stylesheets and XQuery libraries. It allows you to test your templates and queries against input data and compare the result with expected results.
XSpec is managed by Jeni Tennison and Florent Georges in XSpec Google Code repository