Merge "Fix typo in ircbot's default matrix-notifier."
This commit is contained in:
commit
d281563b8b
@ -2754,25 +2754,9 @@ def ircbot(parser, xml_parent, data):
|
||||
* **only-configurations** (default)
|
||||
* **only-parent**
|
||||
|
||||
Example::
|
||||
|
||||
publishers:
|
||||
- ircbot:
|
||||
strategy: all
|
||||
notify-start: false
|
||||
notify-committers: false
|
||||
notify-culprits: false
|
||||
notify-upstream: false
|
||||
notify-fixers: false
|
||||
message-type: summary-scm
|
||||
channels:
|
||||
- name: '#jenkins-channel1'
|
||||
password: secrete
|
||||
notify-only: false
|
||||
- name: '#jenkins-channel2'
|
||||
notify-only: true
|
||||
matrix-notifier: only-configurations
|
||||
Example:
|
||||
|
||||
.. literalinclude:: /../../tests/publishers/fixtures/ircbot001.yaml
|
||||
"""
|
||||
top = XML.SubElement(xml_parent, 'hudson.plugins.ircbot.IrcPublisher')
|
||||
message_dict = {'summary-scm': 'DefaultBuildToChatNotifier',
|
||||
@ -2819,7 +2803,7 @@ def ircbot(parser, xml_parent, data):
|
||||
matrix_dict = {'all': 'ALL',
|
||||
'only-configurations': 'ONLY_CONFIGURATIONS',
|
||||
'only-parent': 'ONLY_PARENT'}
|
||||
matrix = data.get('matrix-notifier', 'only_configurations')
|
||||
matrix = data.get('matrix-notifier', 'only-configurations')
|
||||
if matrix not in matrix_dict:
|
||||
raise JenkinsJobsException("matrix-notifier entered is not valid, "
|
||||
"must be one of: %s" %
|
||||
|
27
tests/publishers/fixtures/ircbot001.xml
Normal file
27
tests/publishers/fixtures/ircbot001.xml
Normal file
@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<project>
|
||||
<publishers>
|
||||
<hudson.plugins.ircbot.IrcPublisher>
|
||||
<buildToChatNotifier class="hudson.plugins.im.build_notify.DefaultBuildToChatNotifier"/>
|
||||
<strategy>ALL</strategy>
|
||||
<targets>
|
||||
<hudson.plugins.im.GroupChatIMMessageTarget>
|
||||
<name>#jenkins-channel1</name>
|
||||
<password>secrete</password>
|
||||
<notificationOnly>false</notificationOnly>
|
||||
</hudson.plugins.im.GroupChatIMMessageTarget>
|
||||
<hudson.plugins.im.GroupChatIMMessageTarget>
|
||||
<name>#jenkins-channel2</name>
|
||||
<password/>
|
||||
<notificationOnly>true</notificationOnly>
|
||||
</hudson.plugins.im.GroupChatIMMessageTarget>
|
||||
</targets>
|
||||
<notifyOnBuildStart>false</notifyOnBuildStart>
|
||||
<notifySuspects>false</notifySuspects>
|
||||
<notifyCulprits>false</notifyCulprits>
|
||||
<notifyFixers>false</notifyFixers>
|
||||
<notifyUpstreamCommitters>false</notifyUpstreamCommitters>
|
||||
<matrixMultiplier>ONLY_CONFIGURATIONS</matrixMultiplier>
|
||||
</hudson.plugins.ircbot.IrcPublisher>
|
||||
</publishers>
|
||||
</project>
|
16
tests/publishers/fixtures/ircbot001.yaml
Normal file
16
tests/publishers/fixtures/ircbot001.yaml
Normal file
@ -0,0 +1,16 @@
|
||||
publishers:
|
||||
- ircbot:
|
||||
strategy: all
|
||||
notify-start: false
|
||||
notify-committers: false
|
||||
notify-culprits: false
|
||||
notify-upstream: false
|
||||
notify-fixers: false
|
||||
message-type: summary-scm
|
||||
channels:
|
||||
- name: '#jenkins-channel1'
|
||||
password: secrete
|
||||
notify-only: false
|
||||
- name: '#jenkins-channel2'
|
||||
notify-only: true
|
||||
matrix-notifier: only-configurations
|
22
tests/publishers/fixtures/ircbot002.xml
Normal file
22
tests/publishers/fixtures/ircbot002.xml
Normal file
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<project>
|
||||
<publishers>
|
||||
<hudson.plugins.ircbot.IrcPublisher>
|
||||
<buildToChatNotifier class="hudson.plugins.im.build_notify.DefaultBuildToChatNotifier"/>
|
||||
<strategy>ALL</strategy>
|
||||
<targets>
|
||||
<hudson.plugins.im.GroupChatIMMessageTarget>
|
||||
<name>#jenkins-channel</name>
|
||||
<password/>
|
||||
<notificationOnly>true</notificationOnly>
|
||||
</hudson.plugins.im.GroupChatIMMessageTarget>
|
||||
</targets>
|
||||
<notifyOnBuildStart>false</notifyOnBuildStart>
|
||||
<notifySuspects>false</notifySuspects>
|
||||
<notifyCulprits>false</notifyCulprits>
|
||||
<notifyFixers>false</notifyFixers>
|
||||
<notifyUpstreamCommitters>false</notifyUpstreamCommitters>
|
||||
<matrixMultiplier>ONLY_CONFIGURATIONS</matrixMultiplier>
|
||||
</hudson.plugins.ircbot.IrcPublisher>
|
||||
</publishers>
|
||||
</project>
|
5
tests/publishers/fixtures/ircbot002.yaml
Normal file
5
tests/publishers/fixtures/ircbot002.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
publishers:
|
||||
- ircbot:
|
||||
channels:
|
||||
- name: '#jenkins-channel'
|
||||
notify-only: true
|
Loading…
Reference in New Issue
Block a user