Skip to content
Browse files

Merge pull request #138 from pguibert6WIND/movevrfdeftodefault

bgp-ecmp-topo1: change default vrf name
  • Loading branch information...
rzalamena committed Oct 30, 2018
2 parents bfe9350 + 53b7916 commit 132ffd115b89efd6c21aba86f2cd362b61035b2f
Showing with 13 additions and 1 deletion.
  1. +13 −1 bgp-ecmp-topo1/
@@ -133,8 +133,20 @@ def test_bgp_convergence():

expected = json.loads(open(reffile).read())

def _output_summary_cmp(router, cmd, data):
Runs `cmd` that returns JSON data (normally the command ends with 'json')
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')
return topotest.json_cmp(output, data)

test_func = functools.partial(
topotest.router_json_cmp, router, 'show ip bgp summary json', expected)
_output_summary_cmp, router, 'show ip bgp summary json', expected)
_, res = topotest.run_and_expect(test_func, None, count=60, wait=0.5)
assertmsg = 'BGP router network did not converge'
assert res is None, assertmsg

0 comments on commit 132ffd1

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