From d66cd3e6dac7e611f7670306f28bf31df11c266c Mon Sep 17 00:00:00 2001 From: Inaky Perez-Gonzalez Date: Thu, 15 Feb 2018 13:28:38 -0800 Subject: [PATCH] wrappers: fix XML node name for scrip-env's only-run-on-parent Jenkins configuration wants it as runOnlyOnParent (vs onlyRunOnParent). https://storyboard.openstack.org/#!/story/2001547 Change-Id: Icbf9b44cabe6f111941659ec5b084d44c0fc8a59 --- jenkins_jobs/modules/wrappers.py | 2 +- tests/wrappers/fixtures/env-script001.xml | 2 +- tests/wrappers/fixtures/env-script002.xml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/jenkins_jobs/modules/wrappers.py b/jenkins_jobs/modules/wrappers.py index b7c7772bd..9d667d076 100644 --- a/jenkins_jobs/modules/wrappers.py +++ b/jenkins_jobs/modules/wrappers.py @@ -1054,7 +1054,7 @@ def env_script(registry, xml_parent, data): mapping = [ ('script-content', 'script', ''), ('script-type', 'scriptType', 'unix-script', valid_script_types), - ('only-run-on-parent', 'onlyRunOnParent', False)] + ('only-run-on-parent', 'runOnlyOnParent', False)] convert_mapping_to_xml(el, data, mapping, fail_required=True) diff --git a/tests/wrappers/fixtures/env-script001.xml b/tests/wrappers/fixtures/env-script001.xml index 23c92e40b..c286dac10 100644 --- a/tests/wrappers/fixtures/env-script001.xml +++ b/tests/wrappers/fixtures/env-script001.xml @@ -4,7 +4,7 @@ unixScript - true + true diff --git a/tests/wrappers/fixtures/env-script002.xml b/tests/wrappers/fixtures/env-script002.xml index 2c962a7b2..7f37cb1e4 100644 --- a/tests/wrappers/fixtures/env-script002.xml +++ b/tests/wrappers/fixtures/env-script002.xml @@ -4,7 +4,7 @@ batchScript - true + true