diff options
Diffstat (limited to 'tests/topotests/lib/bgp.py')
| -rw-r--r-- | tests/topotests/lib/bgp.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/topotests/lib/bgp.py b/tests/topotests/lib/bgp.py index 34afa0d2c1..4dd44e3e9e 100644 --- a/tests/topotests/lib/bgp.py +++ b/tests/topotests/lib/bgp.py @@ -991,11 +991,11 @@ def __create_bgp_unicast_address_family( config_data.append("no {} allowas-in {}".format(neigh_cxt, allow_as_in)) if "shutdown" in peer: - shut_val = peer["shutdown"] - if shut_val is True: - config_data.append("{} shutdown".format(neigh_cxt)) - elif shut_val is False: - config_data.append("no {} shutdown".format(neigh_cxt)) + config_data.append( + "{} {} shutdown".format( + "no" if not peer["shutdown"] else "", neigh_cxt + ) + ) if prefix_lists: for prefix_list in prefix_lists: |
