diff options
Diffstat (limited to 'tests/topotests/lib/bgp.py')
| -rw-r--r-- | tests/topotests/lib/bgp.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/topotests/lib/bgp.py b/tests/topotests/lib/bgp.py index 0bd9408c28..21d4567d6b 100644 --- a/tests/topotests/lib/bgp.py +++ b/tests/topotests/lib/bgp.py @@ -50,6 +50,7 @@ def create_router_bgp(tgen, topo=None, input_dict=None, build=False, load_config "bgp": { "local_as": "200", "router_id": "22.22.22.22", + "bgp_always_compare_med": True, "graceful-restart": { "graceful-restart": True, "preserve-fw-state": True, @@ -343,6 +344,13 @@ def __create_bgp_global(tgen, input_dict, router, build=False): config_data.append(cmd) + if "bgp_always_compare_med" in bgp_data: + bgp_always_compare_med = bgp_data["bgp_always_compare_med"] + if bgp_always_compare_med == True: + config_data.append("bgp always-compare-med") + elif bgp_always_compare_med == False: + config_data.append("no bgp always-compare-med") + logger.debug("Exiting lib API: {}".format(sys._getframe().f_code.co_name)) return config_data |
