Merge "Support Fitnesse results publisher"
This commit is contained in:
commit
ad43311203
@ -3443,6 +3443,27 @@ def ruby_metrics(parser, xml_parent, data):
|
|||||||
raise JenkinsJobsException('Coverage metric targets must be set')
|
raise JenkinsJobsException('Coverage metric targets must be set')
|
||||||
|
|
||||||
|
|
||||||
|
def fitnesse(parser, xml_parent, data):
|
||||||
|
"""yaml: fitnesse
|
||||||
|
Publish Fitnesse test results
|
||||||
|
|
||||||
|
Requires the Jenkins `Fitnesse plugin.
|
||||||
|
<https://wiki.jenkins-ci.org/display/JENKINS/Fitnesse+Plugin>`_
|
||||||
|
|
||||||
|
:arg str results: path specifier for results files
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
.. literalinclude:: /../../tests/publishers/fixtures/fitnesse001.yaml
|
||||||
|
|
||||||
|
"""
|
||||||
|
fitnesse = XML.SubElement(
|
||||||
|
xml_parent,
|
||||||
|
'hudson.plugins.fitnesse.FitnesseResultsRecorder')
|
||||||
|
results = data.get('results', '')
|
||||||
|
XML.SubElement(fitnesse, 'fitnessePathToXmlResultsIn').text = results
|
||||||
|
|
||||||
|
|
||||||
class Publishers(jenkins_jobs.modules.base.Base):
|
class Publishers(jenkins_jobs.modules.base.Base):
|
||||||
sequence = 70
|
sequence = 70
|
||||||
|
|
||||||
|
@ -115,6 +115,7 @@ jenkins_jobs.publishers =
|
|||||||
email=jenkins_jobs.modules.publishers:email
|
email=jenkins_jobs.modules.publishers:email
|
||||||
emotional-jenkins=jenkins_jobs.modules.publishers:emotional_jenkins
|
emotional-jenkins=jenkins_jobs.modules.publishers:emotional_jenkins
|
||||||
fingerprint=jenkins_jobs.modules.publishers:fingerprint
|
fingerprint=jenkins_jobs.modules.publishers:fingerprint
|
||||||
|
fitnesse=jenkins_jobs.modules.publishers:fitnesse
|
||||||
ftp=jenkins_jobs.modules.publishers:ftp
|
ftp=jenkins_jobs.modules.publishers:ftp
|
||||||
git=jenkins_jobs.modules.publishers:git
|
git=jenkins_jobs.modules.publishers:git
|
||||||
github-notifier=jenkins_jobs.modules.publishers:github_notifier
|
github-notifier=jenkins_jobs.modules.publishers:github_notifier
|
||||||
|
8
tests/publishers/fixtures/fitnesse001.xml
Normal file
8
tests/publishers/fixtures/fitnesse001.xml
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<project>
|
||||||
|
<publishers>
|
||||||
|
<hudson.plugins.fitnesse.FitnesseResultsRecorder>
|
||||||
|
<fitnessePathToXmlResultsIn>fitnesse-results/**/*.xml</fitnessePathToXmlResultsIn>
|
||||||
|
</hudson.plugins.fitnesse.FitnesseResultsRecorder>
|
||||||
|
</publishers>
|
||||||
|
</project>
|
3
tests/publishers/fixtures/fitnesse001.yaml
Normal file
3
tests/publishers/fixtures/fitnesse001.yaml
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
publishers:
|
||||||
|
- fitnesse:
|
||||||
|
results: "fitnesse-results/**/*.xml"
|
Loading…
Reference in New Issue
Block a user