Fixed serialization for 'branch-filter-type' of gitlab

tag 'branchFilterType' was introduced only in GitLab+Plugin ver. 1.2.0

Change-Id: I8cee5b4b77431fa78d28fe359a4fafc5609bde3e
Story: 2000875
This commit is contained in:
Bulat Gaifullin 2017-02-21 20:26:04 +03:00
parent 4960f92ad3
commit 38fc311dcd
6 changed files with 6 additions and 6 deletions

View File

@ -1176,7 +1176,7 @@ def gitlab(registry, xml_parent, data):
'triggerOpenMergeRequestOnPush', True)]
convert_mapping_to_xml(gitlab, data, mapping, fail_required=True)
if plugin_ver == pkg_resources.parse_version('1.1.29'):
if plugin_ver < pkg_resources.parse_version('1.2.0'):
if data.get('branch-filter-type', '') == 'All':
data['branch-filter-type'] = ''
valid_filters = ['', 'NameBasedFilter', 'RegexBasedFilter']

View File

@ -3,7 +3,7 @@
<triggers class="vector">
<com.dabsquared.gitlabjenkins.GitLabPushTrigger>
<triggerOpenMergeRequestOnPush>true</triggerOpenMergeRequestOnPush>
<branchFilterType>All</branchFilterType>
<branchFilterName/>
<spec/>
<triggerOnPush>true</triggerOnPush>
<triggerOnMergeRequest>true</triggerOnMergeRequest>

View File

@ -3,7 +3,7 @@
<triggers class="vector">
<com.dabsquared.gitlabjenkins.GitLabPushTrigger>
<triggerOpenMergeRequestOnPush>true</triggerOpenMergeRequestOnPush>
<branchFilterType>All</branchFilterType>
<branchFilterName/>
<spec/>
<triggerOnPush>true</triggerOnPush>
<triggerOnMergeRequest>true</triggerOnMergeRequest>

View File

@ -3,7 +3,7 @@
<triggers class="vector">
<com.dabsquared.gitlabjenkins.GitLabPushTrigger>
<triggerOpenMergeRequestOnPush>true</triggerOpenMergeRequestOnPush>
<branchFilterType>All</branchFilterType>
<branchFilterName/>
<spec/>
<triggerOnPush>true</triggerOnPush>
<triggerOnMergeRequest>true</triggerOnMergeRequest>

View File

@ -3,7 +3,7 @@
<triggers class="vector">
<com.dabsquared.gitlabjenkins.GitLabPushTrigger>
<triggerOpenMergeRequestOnPush>both</triggerOpenMergeRequestOnPush>
<branchFilterType>All</branchFilterType>
<branchFilterName/>
<spec/>
<triggerOnPush>false</triggerOnPush>
<triggerOnMergeRequest>false</triggerOnMergeRequest>

View File

@ -3,7 +3,7 @@
<triggers class="vector">
<com.dabsquared.gitlabjenkins.GitLabPushTrigger>
<triggerOpenMergeRequestOnPush>never</triggerOpenMergeRequestOnPush>
<branchFilterType>All</branchFilterType>
<branchFilterName/>
<spec/>
<triggerOnPush>true</triggerOnPush>
<triggerOnMergeRequest>true</triggerOnMergeRequest>