From a7fc9a27f0dfd809382664ae8e3f9a706a03b998 Mon Sep 17 00:00:00 2001 From: Louis Scalbert Date: Wed, 23 Oct 2024 12:57:27 +0200 Subject: [PATCH] tests: augment bgp bmp test wait time Augment bgp bmp test wait time Signed-off-by: Louis Scalbert --- tests/topotests/bgp_bmp/test_bgp_bmp.py | 14 +++++++------- tests/topotests/bgp_bmp_vrf/test_bgp_bmp_vrf.py | 10 +++++----- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/tests/topotests/bgp_bmp/test_bgp_bmp.py b/tests/topotests/bgp_bmp/test_bgp_bmp.py index 1cf6a0e7f8..e02221c2eb 100644 --- a/tests/topotests/bgp_bmp/test_bgp_bmp.py +++ b/tests/topotests/bgp_bmp/test_bgp_bmp.py @@ -239,7 +239,7 @@ def unicast_prefixes(policy): logger.info("checking for updated prefixes") # check test_func = partial(check_for_prefixes, prefixes, "update", policy) - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the updated prefixes has been failed !." # withdraw prefixes @@ -247,7 +247,7 @@ def unicast_prefixes(policy): logger.info("checking for withdrawed prefxies") # check test_func = partial(check_for_prefixes, prefixes, "withdraw", policy) - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the withdrawed prefixes has been failed !." @@ -274,7 +274,7 @@ def vpn_prefixes(policy): logger.info("checking for updated prefixes") # check test_func = partial(check_for_prefixes, prefixes, "update", policy, labels=labels) - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the updated prefixes has been failed !." # withdraw prefixes @@ -282,7 +282,7 @@ def vpn_prefixes(policy): logger.info("checking for withdrawed prefixes") # check test_func = partial(check_for_prefixes, prefixes, "withdraw", policy) - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the withdrawed prefixes has been failed !." @@ -300,7 +300,7 @@ def test_bmp_server_logging(): return False return True - success, _ = topotest.run_and_expect(check_for_log_file, True, wait=0.5) + success, _ = topotest.run_and_expect(check_for_log_file, True, count=30, wait=1) assert success, "The BMP server is not logging" @@ -314,7 +314,7 @@ def test_peer_up(): logger.info("checking for BMP peers up messages") test_func = partial(check_for_peer_message, peers, "peer up") - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the updated prefixes has been failed !." @@ -353,7 +353,7 @@ def test_peer_down(): logger.info("checking for BMP peers down messages") test_func = partial(check_for_peer_message, peers, "peer down") - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the updated prefixes has been failed !." diff --git a/tests/topotests/bgp_bmp_vrf/test_bgp_bmp_vrf.py b/tests/topotests/bgp_bmp_vrf/test_bgp_bmp_vrf.py index b683920d2e..b95d3f4a57 100644 --- a/tests/topotests/bgp_bmp_vrf/test_bgp_bmp_vrf.py +++ b/tests/topotests/bgp_bmp_vrf/test_bgp_bmp_vrf.py @@ -248,7 +248,7 @@ def unicast_prefixes(policy): logger.info("checking for updated prefixes") # check test_func = partial(check_for_prefixes, prefixes, "update", policy) - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the updated prefixes has been failed !." # withdraw prefixes @@ -256,7 +256,7 @@ def unicast_prefixes(policy): logger.info("checking for withdrawed prefxies") # check test_func = partial(check_for_prefixes, prefixes, "withdraw", policy) - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the withdrawed prefixes has been failed !." @@ -274,7 +274,7 @@ def test_bmp_server_logging(): return False return True - success, _ = topotest.run_and_expect(check_for_log_file, True, wait=0.5) + success, _ = topotest.run_and_expect(check_for_log_file, True, count=30, wait=1) assert success, "The BMP server is not logging" @@ -288,7 +288,7 @@ def test_peer_up(): logger.info("checking for BMP peers up messages") test_func = partial(check_for_peer_message, peers, "peer up") - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the updated prefixes has been failed !." @@ -317,7 +317,7 @@ def test_peer_down(): logger.info("checking for BMP peers down messages") test_func = partial(check_for_peer_message, peers, "peer down") - success, _ = topotest.run_and_expect(test_func, True, wait=0.5) + success, _ = topotest.run_and_expect(test_func, True, count=30, wait=1) assert success, "Checking the updated prefixes has been failed !." -- 2.39.5