Skip to content

Commit

Permalink
topotests: test wrong bfd source in bfd_topo3
Browse files Browse the repository at this point in the history
Test setting a wrong bfd source and restore the source auto parameter.

Signed-off-by: Louis Scalbert <[email protected]>
  • Loading branch information
louis-6wind committed Nov 30, 2023
1 parent e41a87b commit a74d734
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions tests/topotests/bfd_topo3/test_bfd_topo3.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,45 @@ def test_static_route_monitoring_convergence():
expect_static_bfd_output("r6", "bfd-static")


def test_static_route_monitoring_wrong_source():
"Test that static monitoring fails if setting a wrong source."

tgen = get_topogen()
if tgen.routers_have_failure():
pytest.skip(tgen.errors)

logger.info("test route wrong ")

tgen.gears["r3"].vtysh_cmd(
"""
configure
ipv6 route 2001:db8:5::/64 2001:db8:4::3 bfd multi-hop source 2001:db8:4::2 profile slow-tx
"""
)

expect_route_missing("r3", "ipv6", "2001:db8:5::/64")


def test_static_route_monitoring_unset_source():
"Test that static monitoring fails if setting a wrong source."

tgen = get_topogen()
if tgen.routers_have_failure():
pytest.skip(tgen.errors)

logger.info("test route wrong ")

tgen.gears["r3"].vtysh_cmd(
"""
configure
ipv6 route 2001:db8:5::/64 2001:db8:4::3 bfd multi-hop profile slow-tx
"""
)

expect_static_bfd_output("r3", "bfd-static")
expect_static_bfd_output("r6", "bfd-static")


def test_expect_static_rib_removal():
"Test that route got removed from RIB (staticd and bgpd)."

Expand Down

0 comments on commit a74d734

Please sign in to comment.