Skip to content
Browse files

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 <>
  • Loading branch information...
rzalamena committed Nov 6, 2018
1 parent 132ffd1 commit 5a87c583140e713394739b97b78d96cdd859488b
Showing with 6 additions and 4 deletions.
  1. +6 −4 bgp-ecmp-topo1/
@@ -139,10 +139,12 @@ def _output_summary_cmp(router, cmd, data):
and compare with `data` contents.
output = router.vtysh_cmd(cmd, isjson=True)
if output.has_key('ipv4Unicast'):
output['ipv4Unicast']['vrfName'].replace('default', 'Default')
elif output.has_key('vrfName'):
output['vrfName'].replace('default', 'Default')
if 'ipv4Unicast' in output:
output['ipv4Unicast']['vrfName'] = \
'default', 'Default')
elif 'vrfName' in output:
output['vrfName'] = output['vrfName'].replace('default', 'Default')
return topotest.json_cmp(output, data)

test_func = functools.partial(

0 comments on commit 5a87c58

Please sign in to comment.
You can’t perform that action at this time.