title: How to correctly set up TestNG report parsing with Jenkins and Gradle
body: <p>I am trying to get a Jenkins job to run that builds using Gradle and
  runs tests using their Testng integration.</p>
  
  <p>I have the latest Jenkins installed.</p>
  
  <p>I have set up "Publish TestNG Results" and used the pattern
  "*<em>/test-results/TEST-</em>.xml" because I found that after a build I had
  lots of files with paths like this one in my workspace:</p>
  
  <p>workspace/de.lesspain/de.lesspain.scheduling/build/test-results/TEST-de.lesspain.scheduling.CronScheduleTest.xml</p>
  
  <p>What my job reports is lots of the following:</p>
  
  <pre>
  
      Processing '/Users/Shared/Jenkins/Home/jobs/Mediatool-SSH/builds/2014-02-04_16-58-47/testng/testng-results-9.xml'
      Failed to parse XML: only 1.0 is supported as &lt;?xml version not '1.1'
      (position: START_DOCUMENT seen &lt;?xml version="1.1"... @1:19)
      org.xmlpull.v1.XmlPullParserException: only 1.0 is supported as &lt;?xml
      version not '1.1' (position: START_DOCUMENT seen &lt;?xml
      version="1.1"... @1:19)
      at org.xmlpull.mxp1.MXParser.parseXmlDeclWithVersion(MXParser.java:2608)
  
  </pre>
  
  <p>First of all, which of the test result files are the correct ones that
  should be parsed? The ones named testng-results* or
  TEST-.xml?</p>
  
  <p>Then I do not understand, why the pattern above matches in that case
  and then why do I get this error messages when both types of xml files
  generated by testng seem to be declared with xml version 1.1? Is there
  currently a known problem with the combination of jenkins, gradle and
  testng or am I just doing stuff wrong (probably)?</p>
  
  <p>Thanks for any insight,</p>
  
  <p>Robert</p>