]> git.puffer.fish Git - mirror/frr.git/commitdiff
tests: Add a simple ssmping test to the system
authorDonald Sharp <donaldsharp72@gmail.com>
Sun, 13 Apr 2025 17:47:00 +0000 (13:47 -0400)
committerDonald Sharp <sharpd@nvidia.com>
Wed, 23 Apr 2025 17:56:07 +0000 (13:56 -0400)
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 <donaldsharp72@gmail.com>
tests/topotests/pim_basic/test_pim.py

index 3ccc4251a50db54a0feabf14218fab73597ffa64..d0787b27be81aed59b6a5496af7082442ff3a221 100644 (file)
@@ -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()