diff options
| author | Christian Hopps <chopps@labn.net> | 2023-04-21 21:59:33 -0400 | 
|---|---|---|
| committer | Christian Hopps <chopps@labn.net> | 2023-04-21 22:10:54 -0400 | 
| commit | 260268c45cd5f705d72ab2c195b7ed32c80ea40a (patch) | |
| tree | baa141cfb8eee39d94f5ebb7a37b09fba1db7161 /tests/topotests/bgp_gr_functionality_topo1 | |
| parent | ff28990ee4312570c6e340b4421b6316d2c51a87 (diff) | |
tests: fix check for daemon startup, remove sleep hack
- Remove the .pid and .vty files and then wait for them to show back up.
- Fix broken BGP GR test to not fail now that it's bug is exposed. It
only worked b/c when starting a daemon the pid file still existed and
blocked the bogus second BGP launch from happening.
Signed-off-by: Christian Hopps <chopps@labn.net>
Diffstat (limited to 'tests/topotests/bgp_gr_functionality_topo1')
| -rw-r--r-- | tests/topotests/bgp_gr_functionality_topo1/test_bgp_gr_functionality_topo1-3.py | 30 | 
1 files changed, 3 insertions, 27 deletions
diff --git a/tests/topotests/bgp_gr_functionality_topo1/test_bgp_gr_functionality_topo1-3.py b/tests/topotests/bgp_gr_functionality_topo1/test_bgp_gr_functionality_topo1-3.py index f8a01a1c9d..1a8f8302ff 100644 --- a/tests/topotests/bgp_gr_functionality_topo1/test_bgp_gr_functionality_topo1-3.py +++ b/tests/topotests/bgp_gr_functionality_topo1/test_bgp_gr_functionality_topo1-3.py @@ -1159,7 +1159,7 @@ def test_BGP_GR_TC_31_2_p1(request):      reset_config_on_routers(tgen)      logger.info( -        "[Phase 1] : Test Setup " "[Disable Mode]R1-----R2[Restart Mode] initialized  " +        "[Phase 1] : Test Setup " "[Disable Mode]R1-----R2[Helper Mode] initialized  "      )      # Configure graceful-restart @@ -1251,7 +1251,7 @@ def test_BGP_GR_TC_31_2_p1(request):              tc_name, result          ) -    logger.info("[Phase 2] : R2 Goes from Disable to Restart Mode  ") +    logger.info("[Phase 2] : R1 Goes from Disable to Restart Mode  ")      # Configure graceful-restart      input_dict = { @@ -1356,31 +1356,7 @@ def test_BGP_GR_TC_31_2_p1(request):          },      } -    # here the verify_graceful_restart fro the neighbor would be -    # "NotReceived" as the latest GR config is not yet applied. -    for addr_type in ADDR_TYPES: -        result = verify_graceful_restart( -            tgen, topo, addr_type, input_dict, dut="r1", peer="r2" -        ) -        assert result is True, "Testcase {} : Failed \n Error {}".format( -            tc_name, result -        ) - -    for addr_type in ADDR_TYPES: -        # Verifying RIB routes -        next_hop = next_hop_per_address_family( -            tgen, dut, peer, addr_type, NEXT_HOP_IP_2 -        ) -        input_topo = {key: topo["routers"][key] for key in ["r2"]} -        result = verify_rib(tgen, addr_type, dut, input_topo, next_hop, protocol) -        assert result is True, "Testcase {} : Failed \n Error {}".format( -            tc_name, result -        ) - -    logger.info("[Phase 6] : R1 is about to come up now  ") -    start_router_daemons(tgen, "r1", ["bgpd"]) - -    logger.info("[Phase 4] : R1 is UP now, so time to collect GR stats ") +    logger.info("[Phase 4] : R1 is UP and GR state is correct ")      for addr_type in ADDR_TYPES:          result = verify_graceful_restart(  | 
