diff options
author | Giga Murphy <giga1699@gmail.com> | 2023-08-20 15:46:50 +0000 |
---|---|---|
committer | Giga Murphy <giga1699@gmail.com> | 2023-08-20 15:46:50 +0000 |
commit | 525beb3202bb3ccb15c28d2c41e24e68762af253 (patch) | |
tree | 6ce4a98ac789cd6344cc99b899970986d84ecd71 /smoketest/scripts/cli | |
parent | d110af71cb1c8b62758feae724e13877a278c578 (diff) | |
download | vyos-1x-525beb3202bb3ccb15c28d2c41e24e68762af253.tar.gz vyos-1x-525beb3202bb3ccb15c28d2c41e24e68762af253.zip |
T5447: Implement maintainer feedback
Diffstat (limited to 'smoketest/scripts/cli')
-rwxr-xr-x | smoketest/scripts/cli/test_interfaces_macsec.py | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/smoketest/scripts/cli/test_interfaces_macsec.py b/smoketest/scripts/cli/test_interfaces_macsec.py index 8c9867500..30d1ad659 100755 --- a/smoketest/scripts/cli/test_interfaces_macsec.py +++ b/smoketest/scripts/cli/test_interfaces_macsec.py @@ -245,10 +245,10 @@ class MACsecInterfaceTest(BasicInterfaceTest.TestCase): self.cli_commit() # check validate() - tx-key length must match cipher - self.cli_set(self._base_path + [interface, 'security', 'static', 'tx-key', tx_key_2]) + self.cli_set(self._base_path + [interface, 'security', 'static', 'key', tx_key_2]) with self.assertRaises(ConfigSessionError): self.cli_commit() - self.cli_set(self._base_path + [interface, 'security', 'static', 'tx-key', tx_key_1]) + self.cli_set(self._base_path + [interface, 'security', 'static', 'key', tx_key_1]) # check validate() - at least one peer must be defined with self.assertRaises(ConfigSessionError): @@ -262,23 +262,22 @@ class MACsecInterfaceTest(BasicInterfaceTest.TestCase): with self.assertRaises(ConfigSessionError): self.cli_commit() self.cli_delete(self._base_path + [interface, 'security', 'static', 'peer', 'TESTPEER', 'mac']) - self.cli_set(self._base_path + [interface, 'security', 'static', 'peer', 'TESTPEER', 'rx-key', rx_key_1]) + self.cli_set(self._base_path + [interface, 'security', 'static', 'peer', 'TESTPEER', 'key', rx_key_1]) with self.assertRaises(ConfigSessionError): self.cli_commit() self.cli_set(self._base_path + [interface, 'security', 'static', 'peer', 'TESTPEER', 'mac', peer_mac]) # check validate() - peer rx-key length must match cipher self.cli_set(self._base_path + [interface, 'security', 'cipher', cipher2]) - self.cli_set(self._base_path + [interface, 'security', 'static', 'tx-key', tx_key_2]) + self.cli_set(self._base_path + [interface, 'security', 'static', 'key', tx_key_2]) with self.assertRaises(ConfigSessionError): self.cli_commit() - self.cli_set(self._base_path + [interface, 'security', 'static', 'peer', 'TESTPEER', 'rx-key', rx_key_2]) + self.cli_set(self._base_path + [interface, 'security', 'static', 'peer', 'TESTPEER', 'key', rx_key_2]) # final commit and verify self.cli_commit() self.assertIn(interface, interfaces()) self.assertEqual(cipher2, get_cipher(interface)) - # Add checks for keys? self.assertTrue(os.path.isdir(f'/sys/class/net/{interface}')) if __name__ == '__main__': |