daemon: Check if devices are found when generating deployed scenario XML.
This commit is contained in:
parent
ec5635c4a4
commit
f16f11c272
1 changed files with 4 additions and 0 deletions
|
@ -132,6 +132,10 @@ class CoreDeploymentWriter(object):
|
|||
assert isinstance(obj, nodes.PyCoreNode)
|
||||
el = self.add_host(parent, obj.name)
|
||||
device = self.find_device(self.root.baseEle, obj.name)
|
||||
if device is None:
|
||||
self.session.warn('corresponding XML device not found for %s' %
|
||||
(obj.name))
|
||||
return
|
||||
self.add_mapping(device, 'testHost', el.getAttribute('id'))
|
||||
self.add_type(el, 'virtual')
|
||||
for netif in obj.netifs():
|
||||
|
|
Loading…
Reference in a new issue