summaryrefslogtreecommitdiff
path: root/smoketest/scripts/cli
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2026-06-25 16:33:26 +0200
committerGitHub <noreply@github.com>2026-06-25 16:33:26 +0200
commita141346934897cf25df38f3fe916bae9d06b886d (patch)
tree8391e371c383fb8e65f610edbff54e54fd632448 /smoketest/scripts/cli
parent92de46c87e27415105614172c891fff6cfbbc816 (diff)
parenta83edf1a11c86df0a1419930b31544296a7a6e6c (diff)
downloadvyos-1x-a141346934897cf25df38f3fe916bae9d06b886d.tar.gz
vyos-1x-a141346934897cf25df38f3fe916bae9d06b886d.zip
Merge pull request #5290 from natali-rs1985/T9013
bgp: T9013: Add BMP source-interface support
Diffstat (limited to 'smoketest/scripts/cli')
-rwxr-xr-xsmoketest/scripts/cli/test_protocols_bgp.py18
1 files changed, 17 insertions, 1 deletions
diff --git a/smoketest/scripts/cli/test_protocols_bgp.py b/smoketest/scripts/cli/test_protocols_bgp.py
index 680829bce..cee52e548 100755
--- a/smoketest/scripts/cli/test_protocols_bgp.py
+++ b/smoketest/scripts/cli/test_protocols_bgp.py
@@ -1852,6 +1852,7 @@ class TestProtocolsBGP(VyOSUnitTestSHIM.TestCase):
mirror_buffer = '32000000'
bmp_path = base_path + ['bmp']
target_path = bmp_path + ['target', target_name]
+ source_iface = 'eth0'
# by default the 'bmp' module not loaded for the bgpd expect Error
self.cli_set(bmp_path)
@@ -1879,6 +1880,7 @@ class TestProtocolsBGP(VyOSUnitTestSHIM.TestCase):
# config other bmp options
self.cli_set(target_path + ['address', target_address])
+ self.cli_set(target_path + ['source-interface', source_iface])
self.cli_set(bmp_path + ['mirror-buffer-limit', mirror_buffer])
self.cli_set(target_path + ['port', target_port])
self.cli_set(target_path + ['min-retry', min_retry])
@@ -1899,7 +1901,21 @@ class TestProtocolsBGP(VyOSUnitTestSHIM.TestCase):
self.assertIn(f'bmp monitor ipv6 unicast {monitor_ipv6}', frrconfig)
self.assertIn(f'bmp monitor ipv4 unicast loc-rib', frrconfig)
self.assertIn(f'bmp monitor ipv6 unicast loc-rib', frrconfig)
- self.assertIn(f'bmp connect {target_address} port {target_port} min-retry {min_retry} max-retry {max_retry}', frrconfig)
+ self.assertIn(
+ f'bmp connect {target_address} port {target_port} min-retry {min_retry} max-retry {max_retry} source-interface {source_iface}',
+ frrconfig,
+ )
+
+ # verify source-interface is removed from FRR config after deletion
+ self.cli_delete(target_path + ['source-interface'])
+ self.cli_commit()
+
+ frrconfig = self.getFRRconfig(f'router bgp {ASN}', stop_section='^exit')
+ self.assertIn(
+ f'bmp connect {target_address} port {target_port} min-retry {min_retry} max-retry {max_retry}',
+ frrconfig,
+ )
+ self.assertNotIn('source-interface', frrconfig)
def test_bgp_100_link_state(self):
router_id = '127.0.0.1'