Merge "Update Plot plugin"

This commit is contained in:
Jenkins 2016-05-16 14:22:56 +00:00 committed by Gerrit Code Review
commit 4b0449e58f

View File

@ -3582,10 +3582,9 @@ def plot(parser, xml_parent, data):
Requires the Jenkins :jenkins-wiki:`Plot Plugin <Plot+Plugin>`. Requires the Jenkins :jenkins-wiki:`Plot Plugin <Plot+Plugin>`.
:arg str title: title for the graph :arg str title: title for the graph (default: '')
(default: '') :arg str yaxis: title of Y axis (default: '')
:arg str yaxis: title of Y axis :arg str group: name of the group to which the plot belongs (required)
:arg str group: name of the group to which the plot belongs
:arg int num-builds: number of builds to plot across :arg int num-builds: number of builds to plot across
(default: plot all builds) (default: plot all builds)
:arg str style: Specifies the graph style of the plot :arg str style: Specifies the graph style of the plot
@ -3716,16 +3715,16 @@ def plot(parser, xml_parent, data):
XML.SubElement(subserie, 'nodeTypeString').text = \ XML.SubElement(subserie, 'nodeTypeString').text = \
xpath_dict.get(xpathtype) xpath_dict.get(xpathtype)
XML.SubElement(subserie, 'fileType').text = serie.get('format') XML.SubElement(subserie, 'fileType').text = serie.get('format')
XML.SubElement(plugin, 'group').text = plot['group']
XML.SubElement(plugin, 'useDescr').text = \ mappings = [
str(plot.get('use-description', False)).lower() ('group', 'group', None),
XML.SubElement(plugin, 'exclZero').text = \ ('use-description', 'useDescr', False),
str(plot.get('exclude-zero-yaxis', False)).lower() ('exclude-zero-yaxis', 'exclZero', False),
XML.SubElement(plugin, 'logarithmic').text = \ ('logarithmic-yaxis', 'logarithmic', False),
str(plot.get('logarithmic-yaxis', False)).lower() ('keep-records', 'keepRecords', False),
XML.SubElement(plugin, 'keepRecords').text = \ ('num-builds', 'numBuilds', '')]
str(plot.get('keep-records', False)).lower() convert_mapping_to_xml(plugin, plot, mappings, fail_required=True)
XML.SubElement(plugin, 'numBuilds').text = plot.get('num-builds', '')
style_list = ['area', 'bar', 'bar3d', 'line', 'line3d', 'stackedArea', style_list = ['area', 'bar', 'bar3d', 'line', 'line3d', 'stackedArea',
'stackedbar', 'stackedbar3d', 'waterfall'] 'stackedbar', 'stackedbar3d', 'waterfall']
style = plot.get('style', 'line') style = plot.get('style', 'line')