mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-11 11:21:07 +00:00
bgp-ecmp-topo1: fix vrf default change
Python's `string' method 'replace' doesn't actually modify the string, instead it returns a new string with the modified content. Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
This commit is contained in:
parent
f847adaf8f
commit
47bbb80ad2
@ -139,10 +139,12 @@ def test_bgp_convergence():
|
|||||||
and compare with `data` contents.
|
and compare with `data` contents.
|
||||||
"""
|
"""
|
||||||
output = router.vtysh_cmd(cmd, isjson=True)
|
output = router.vtysh_cmd(cmd, isjson=True)
|
||||||
if output.has_key('ipv4Unicast'):
|
if 'ipv4Unicast' in output:
|
||||||
output['ipv4Unicast']['vrfName'].replace('default', 'Default')
|
output['ipv4Unicast']['vrfName'] = \
|
||||||
elif output.has_key('vrfName'):
|
output['ipv4Unicast']['vrfName'].replace(
|
||||||
output['vrfName'].replace('default', 'Default')
|
'default', 'Default')
|
||||||
|
elif 'vrfName' in output:
|
||||||
|
output['vrfName'] = output['vrfName'].replace('default', 'Default')
|
||||||
return topotest.json_cmp(output, data)
|
return topotest.json_cmp(output, data)
|
||||||
|
|
||||||
test_func = functools.partial(
|
test_func = functools.partial(
|
||||||
|
Loading…
Reference in New Issue
Block a user