diff options
author | Daniil Baturin <daniil@vyos.io> | 2022-05-07 11:42:15 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-07 11:42:15 +0300 |
commit | 56764361d87a0dbc95a336b847273935c6951aec (patch) | |
tree | 7383ddd55eee3b5850c1acbd4f59e041c820bf15 /smoketest/scripts/cli | |
parent | 2c29a3b3b46c7570f4a509f413b208348c0ce647 (diff) | |
parent | d903c9b43225bc8606c72701b319cef9e39c3eb4 (diff) | |
download | vyos-1x-56764361d87a0dbc95a336b847273935c6951aec.tar.gz vyos-1x-56764361d87a0dbc95a336b847273935c6951aec.zip |
Merge pull request #1318 from c-po/t4361-equuleus-backport
T4361: equuleus backport vyos.config fix
Diffstat (limited to 'smoketest/scripts/cli')
-rwxr-xr-x | smoketest/scripts/cli/test_interfaces_bonding.py | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/smoketest/scripts/cli/test_interfaces_bonding.py b/smoketest/scripts/cli/test_interfaces_bonding.py index 4f2fe979a..9bb561275 100755 --- a/smoketest/scripts/cli/test_interfaces_bonding.py +++ b/smoketest/scripts/cli/test_interfaces_bonding.py @@ -165,5 +165,27 @@ class BondingInterfaceTest(BasicInterfaceTest.TestCase): self.cli_commit() + def test_bonding_uniq_member_description(self): + ethernet_path = ['interfaces', 'ethernet'] + for interface in self._interfaces: + for option in self._options.get(interface, []): + self.cli_set(self._base_path + [interface] + option.split()) + + self.cli_commit() + + # Add any changes on bonding members + # For example add description on separate ethX interfaces + for interface in self._interfaces: + for member in self._members: + self.cli_set(ethernet_path + [member, 'description', member + '_interface']) + + self.cli_commit() + + # verify config + for interface in self._interfaces: + slaves = read_file(f'/sys/class/net/{interface}/bonding/slaves').split() + for member in self._members: + self.assertIn(member, slaves) + if __name__ == '__main__': unittest.main(verbosity=2) |