Skip to content

Commit

Permalink
tests: fix no vrf1 in bgp_bmp r2
Browse files Browse the repository at this point in the history
The bgp_bmp test is failing because r2 lacks the vrf1 VRF, which
prevents it from exporting VPN prefixes from the configured vrf1 BGP
instance. Previous versions allowed the export of static BGP prefixes
from a non-existent VRF, so the test passed under those conditions.

Add a vrf1 VRF on r2.

Fixes: d748544 ("topotests: add basic bgp bmp test")
Signed-off-by: Louis Scalbert <[email protected]>
  • Loading branch information
louis-6wind committed Nov 14, 2024
1 parent e092627 commit 5bd08ca
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/topotests/bgp_bmp/test_bgp_bmp.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,13 @@ def setup_module(mod):
"tcpdump -nni r1-eth0 -s 0 -w /tmp/bmp.pcap &", stdout=None
)

tgen.net["r2"].cmd(
"""
ip link add vrf1 type vrf table 10
ip link set vrf1 up
"""
)

for rname, router in tgen.routers().items():
router.load_config(
TopoRouter.RD_ZEBRA, os.path.join(CWD, "{}/zebra.conf".format(rname))
Expand Down

0 comments on commit 5bd08ca

Please sign in to comment.