Fix junos integration zuul CI failures (#57309)

This commit is contained in:
Ganesh Nalawade 2019-06-10 07:10:58 -07:00 committed by Daniel Mellado Area
commit a867ced4de
9 changed files with 318 additions and 234 deletions

View file

@ -223,9 +223,9 @@ class NetconfBase(AnsiblePlugin):
"""
if rpc_command is None:
raise ValueError('rpc_command value must be provided')
req = fromstring(rpc_command)
resp = self.m.dispatch(req, source=source, filter=filter)
return resp.data_xml if resp.data_ele else resp.xml
resp = self.m.dispatch(fromstring(rpc_command), source=source, filter=filter)
return resp.data_xml if hasattr(resp, 'data_xml') else resp.xml
@ensure_connected
def lock(self, target="candidate"):