Avoid extra XML elements in views

Non-view modules get called and add empty "actions", "builders" and
other XML elements to view XML tags where they are not supposed to be,
this causes Jenkins "Old data" warnings

Change-Id: Ie031192dca7ac0920e0953d533ed15c22db91022
Story: 2002159
Task: 20008
This commit is contained in:
Aigars Mahinovs 2018-08-13 12:39:58 +02:00
parent b23394b47b
commit 58c51178b3

View File

@ -90,7 +90,8 @@ class XmlGenerator(object):
Mod = ep.load() Mod = ep.load()
mod = Mod(self.registry) mod = Mod(self.registry)
xml = mod.root_xml(data) xml = mod.root_xml(data)
self._gen_xml(xml, data) if "view-type" not in data:
self._gen_xml(xml, data)
obj = XmlJob(xml, data['name']) obj = XmlJob(xml, data['name'])
return obj return obj