diff --git a/jenkins_jobs/modules/hipchat_notif.py b/jenkins_jobs/modules/hipchat_notif.py index f631357a0..c342a55ec 100644 --- a/jenkins_jobs/modules/hipchat_notif.py +++ b/jenkins_jobs/modules/hipchat_notif.py @@ -145,7 +145,8 @@ class HipChat(jenkins_jobs.modules.base.Base): "'hipchat' module supports the old plugin versions <1.9, " "newer versions are supported via the 'publishers' module. " "Please upgrade you job definition") - return self.registry.dispatch('publisher', publishers, data) + component = {'hipchat': hipchat} + return self.registry.dispatch('publisher', publishers, component) else: properties = xml_parent.find('properties') if properties is None: diff --git a/tests/yamlparser/fixtures/hipchat1.plugins_info.yaml b/tests/yamlparser/fixtures/hipchat1.plugins_info.yaml new file mode 100644 index 000000000..25ec76fab --- /dev/null +++ b/tests/yamlparser/fixtures/hipchat1.plugins_info.yaml @@ -0,0 +1,3 @@ +- longName: 'Jenkins HipChat Plugin' + shortName: 'hipchat' + version: "2.1.1" diff --git a/tests/yamlparser/fixtures/hipchat1.xml b/tests/yamlparser/fixtures/hipchat1.xml new file mode 100644 index 000000000..e5ec0d317 --- /dev/null +++ b/tests/yamlparser/fixtures/hipchat1.xml @@ -0,0 +1,27 @@ + + + + desc<!-- Managed by Jenkins Job Builder --> + false + false + false + false + true + + + + + + + room1 + true + false + false + false + false + false + false + + + + diff --git a/tests/yamlparser/fixtures/hipchat1.yaml b/tests/yamlparser/fixtures/hipchat1.yaml new file mode 100644 index 000000000..7a797fc23 --- /dev/null +++ b/tests/yamlparser/fixtures/hipchat1.yaml @@ -0,0 +1,17 @@ +- defaults: + name: global + project-type: freestyle + description: desc + +- project: + name: hipchat1 + jobs: + - 'hipchat1-tpl' + +- job-template: + name: 'hipchat1-tpl' + scm: [] + hipchat: + enabled: true + rooms: [room1] + notify-start: true