Unfortunately, I have to create a new Jenkins job as "freestyle", since a Maven Jenkins job doesn't have the checkbox "Publish JUnit test result report". Doing this, I get the following error message upon execution of ready-api tests:
java.io.IOException: Failed to read /var/jenkins_home/jobs/app-test-freestyle/workspace/readme.md
Is this really a JUnit report file? Your configuration must be matching too many files
at hudson.tasks.junit.TestResult.parse(TestResult.java:281)
at hudson.tasks.junit.TestResult.parsePossiblyEmpty(TestResult.java:229)
at hudson.tasks.junit.TestResult.parse(TestResult.java:164)
at hudson.tasks.junit.TestResult.parse(TestResult.java:147)
at hudson.tasks.junit.TestResult.<init>(TestResult.java:123)
at hudson.tasks.junit.JUnitParser$ParseResultCallable.invoke(JUnitParser.java:117)
at hudson.tasks.junit.JUnitParser$ParseResultCallable.invoke(JUnitParser.java:90)
at hudson.FilePath.act(FilePath.java:980)
at hudson.FilePath.act(FilePath.java:958)
at hudson.tasks.junit.JUnitParser.parse(JUnitParser.java:87)
at hudson.tasks.junit.JUnitResultArchiver.parse(JUnitResultArchiver.java:129)
at hudson.tasks.junit.JUnitResultArchiver.perform(JUnitResultArchiver.java:141)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:770)
at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:734)
at hudson.model.Build$BuildExecution.post2(Build.java:183)
at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:683)
at hudson.model.Run.execute(Run.java:1770)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:89)
at hudson.model.Executor.run(Executor.java:240)
Caused by: org.dom4j.DocumentException: Error on line 1 of document file:///var/jenkins_home/jobs/app-test-freestyle/workspace/readme.md : Content is not allowed in prolog. Nested exception: Content is not allowed in prolog.
at org.dom4j.io.SAXReader.read(SAXReader.java:482)
at org.dom4j.io.SAXReader.read(SAXReader.java:264)
at hudson.tasks.junit.SuiteResult.parse(SuiteResult.java:123)
at hudson.tasks.junit.TestResult.parse(TestResult.java:273)
... 20 more
Caused by: org.xml.sax.SAXParseException; systemId: file:///var/jenkins_home/jobs/app-test-freestyle/workspace/readme.md; lineNumber: 1; columnNumber: 1; Content is not allowed in prolog.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:198)
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:177)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:441)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:368)
at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1436)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:999)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:117)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:648)
at org.dom4j.io.SAXReader.read(SAXReader.java:465)
... 23 more
Jenkins seems to assume that a readme file (readme.md) is the generated Junit test result report file. This is wrong in this testcase, that's why I was asking which xml I have to specify in Jenkins to use as test result report file.