summaryrefslogtreecommitdiff
path: root/smoketest/scripts/cli/test_interfaces_bonding.py
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2023-11-07 07:06:09 +0100
committerGitHub <noreply@github.com>2023-11-07 07:06:09 +0100
commit7a4d59acaf62908a20f7aa143816c608f5479fb2 (patch)
tree337844bbc582be84a091842fed89ec48714fb51c /smoketest/scripts/cli/test_interfaces_bonding.py
parent7b7d422e11b14989591d6847b59062b13f98d7b9 (diff)
parent91a65d29555050db4cee66568ac905ab74844823 (diff)
downloadvyos-1x-7a4d59acaf62908a20f7aa143816c608f5479fb2.tar.gz
vyos-1x-7a4d59acaf62908a20f7aa143816c608f5479fb2.zip
Merge pull request #2444 from vyos/mergify/bp/sagitta/pr-2416
T5698 EVPN ESI Multihoming (backport #2416)
Diffstat (limited to 'smoketest/scripts/cli/test_interfaces_bonding.py')
-rwxr-xr-xsmoketest/scripts/cli/test_interfaces_bonding.py40
1 files changed, 40 insertions, 0 deletions
diff --git a/smoketest/scripts/cli/test_interfaces_bonding.py b/smoketest/scripts/cli/test_interfaces_bonding.py
index 8867cb427..419de774a 100755
--- a/smoketest/scripts/cli/test_interfaces_bonding.py
+++ b/smoketest/scripts/cli/test_interfaces_bonding.py
@@ -241,5 +241,45 @@ class BondingInterfaceTest(BasicInterfaceTest.TestCase):
for member in self._members:
self.assertIn(member, slaves)
+ def test_bonding_evpn_multihoming(self):
+ id = '5'
+ for interface in self._interfaces:
+ for option in self._options.get(interface, []):
+ self.cli_set(self._base_path + [interface] + option.split())
+
+ self.cli_set(self._base_path + [interface, 'evpn', 'es-id', id])
+ self.cli_set(self._base_path + [interface, 'evpn', 'es-df-pref', id])
+ self.cli_set(self._base_path + [interface, 'evpn', 'es-sys-mac', f'00:12:34:56:78:0{id}'])
+ self.cli_set(self._base_path + [interface, 'evpn', 'uplink'])
+
+ id = int(id) + 1
+
+ self.cli_commit()
+
+ id = '5'
+ for interface in self._interfaces:
+ frrconfig = self.getFRRconfig(f'interface {interface}', daemon='zebra')
+
+ self.assertIn(f' evpn mh es-id {id}', frrconfig)
+ self.assertIn(f' evpn mh es-df-pref {id}', frrconfig)
+ self.assertIn(f' evpn mh es-sys-mac 00:12:34:56:78:0{id}', frrconfig)
+ self.assertIn(f' evpn mh uplink', frrconfig)
+
+ id = int(id) + 1
+
+ for interface in self._interfaces:
+ self.cli_delete(self._base_path + [interface, 'evpn', 'es-id'])
+ self.cli_delete(self._base_path + [interface, 'evpn', 'es-df-pref'])
+
+ self.cli_commit()
+
+ id = '5'
+ for interface in self._interfaces:
+ frrconfig = self.getFRRconfig(f'interface {interface}', daemon='zebra')
+ self.assertIn(f' evpn mh es-sys-mac 00:12:34:56:78:0{id}', frrconfig)
+ self.assertIn(f' evpn mh uplink', frrconfig)
+
+ id = int(id) + 1
+
if __name__ == '__main__':
unittest.main(verbosity=2)