From 3b780b023a41425531c5c286f114484b13ff4fe1 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Sun, 13 Apr 2025 13:47:00 -0400 Subject: [PATCH] tests: Add a simple ssmping test to the system There are no tests that attempt to cover the ssmpingd functionality in pimd. Add a very very simple test case. This test requires the ssmping package to be installed. Signed-off-by: Donald Sharp --- tests/topotests/pim_basic/test_pim.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/tests/topotests/pim_basic/test_pim.py b/tests/topotests/pim_basic/test_pim.py index 3ccc4251a5..d0787b27be 100644 --- a/tests/topotests/pim_basic/test_pim.py +++ b/tests/topotests/pim_basic/test_pim.py @@ -217,6 +217,27 @@ def test_pim_igmp_report(): p.wait() +def test_pim_ssm_ping(): + "Test SSM ping functionality between r1 and r2" + logger.info("Testing SSM ping from r1 to r2") + + tgen = get_topogen() + + if tgen.routers_have_failure(): + pytest.skip(tgen.errors) + + r1 = tgen.gears["r1"] + r2 = tgen.gears["r2"] + + r2.vtysh_cmd("conf\nip ssmpingd 10.0.20.2") + + # Run ssmping from r1 to r2 + output = r1.run("ssmping -I r1-eth0 10.0.20.2 -c 5") + + # Check if we got successful responses + assert "5 packets received" in output, "SSM ping failed" + + def test_memory_leak(): "Run the memory leak test and report results." tgen = get_topogen() -- 2.39.5