]> git.puffer.fish Git - matthieu/frr.git/commitdiff
tests: add one more check for default-originate with route-map
authorIgor Ryzhov <iryzhov@nfware.com>
Wed, 8 Sep 2021 18:10:12 +0000 (21:10 +0300)
committermergify-bot <noreply@mergify.io>
Thu, 16 Sep 2021 10:51:58 +0000 (10:51 +0000)
Make sure that we don't set communities from a random RIB route when
originating the default route.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
(cherry picked from commit 68d4b72ff37eb2d6d851b0dcd9e69e7a248b6cec)

tests/topotests/bgp_default_route_route_map_match_set/test_bgp_default-originate_route-map_match_set.py

index 12d1d01bfb6ea26b7c8516b63b5496ff2d8e9288..94b3e8295b4d28f6ecd5286b900632d21b80a8df 100644 (file)
@@ -95,7 +95,13 @@ def test_bgp_default_originate_route_map():
     def _bgp_default_route_has_metric(router):
         output = json.loads(router.vtysh_cmd("show ip bgp 0.0.0.0/0 json"))
         expected = {
-            "paths": [{"aspath": {"string": "65000 65000 65000 65000"}, "metric": 123}]
+            "paths": [
+                {
+                    "aspath": {"string": "65000 65000 65000 65000"},
+                    "metric": 123,
+                    "community": None,
+                }
+            ]
         }
         return topotest.json_cmp(output, expected)