]> git.puffer.fish Git - mirror/frr.git/commitdiff
topotests: nhrp_topo, test absence of noarp flag
authorLouis Scalbert <louis.scalbert@6wind.com>
Thu, 11 Jan 2024 10:17:54 +0000 (11:17 +0100)
committerLouis Scalbert <louis.scalbert@6wind.com>
Wed, 24 Jan 2024 09:05:49 +0000 (10:05 +0100)
Test the absence the NOARP flag on rX-gre0 interfaces. It is present by
default.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
tests/topotests/nhrp_topo/test_nhrp_topo.py

index 78b82eda79b27ef57b8224119a8f4de6ea8ea348..26115de2b8666a7ebcf88272310ad40cfb7c7f8f 100644 (file)
@@ -182,6 +182,27 @@ def test_protocols_convergence():
         assertmsg = '"{}" JSON output mismatches'.format(router.name)
         assert result is None, assertmsg
 
+    # check that the NOARP flag is removed from rX-gre0 interfaces
+    for rname, router in router_list.items():
+        if rname == "r3":
+            continue
+
+        expected = {
+            "{}-gre0".format(rname): {
+                "flags": "<UP,RUNNING>",
+            }
+        }
+        test_func = partial(
+            topotest.router_json_cmp,
+            router,
+            "show interface {}-gre0 json".format(rname),
+            expected,
+        )
+        _, result = topotest.run_and_expect(test_func, None, count=10, wait=0.5)
+
+        assertmsg = '"{}-gre0 interface flags incorrect'.format(router.name)
+        assert result is None, assertmsg
+
     for rname, router in router_list.items():
         if rname == "r3":
             continue