diff options
Diffstat (limited to 'smoketest/scripts/cli')
-rw-r--r-- | smoketest/scripts/cli/base_interfaces_test.py | 4 | ||||
-rwxr-xr-x | smoketest/scripts/cli/test_interfaces_bonding.py | 6 | ||||
-rwxr-xr-x | smoketest/scripts/cli/test_interfaces_macsec.py | 4 | ||||
-rwxr-xr-x | smoketest/scripts/cli/test_interfaces_tunnel.py | 12 |
4 files changed, 13 insertions, 13 deletions
diff --git a/smoketest/scripts/cli/base_interfaces_test.py b/smoketest/scripts/cli/base_interfaces_test.py index 4e11c193a..87a572a56 100644 --- a/smoketest/scripts/cli/base_interfaces_test.py +++ b/smoketest/scripts/cli/base_interfaces_test.py @@ -29,7 +29,7 @@ from vyos.util import read_file from vyos.util import cmd from vyos.util import dict_search from vyos.util import process_named_running -from vyos.util import get_json_iface_options +from vyos.util import get_interface_config from vyos.validate import is_intf_addr_assigned from vyos.validate import is_ipv6_link_local @@ -353,7 +353,7 @@ class BasicInterfaceTest: for interface in self._interfaces: for vif_s in self._qinq_range: - tmp = get_json_iface_options(f'{interface}.{vif_s}') + tmp = get_interface_config(f'{interface}.{vif_s}') self.assertEqual(dict_search('linkinfo.info_data.protocol', tmp), '802.1ad') for vif_c in self._vlan_range: diff --git a/smoketest/scripts/cli/test_interfaces_bonding.py b/smoketest/scripts/cli/test_interfaces_bonding.py index 9480263d8..4771eb6b6 100755 --- a/smoketest/scripts/cli/test_interfaces_bonding.py +++ b/smoketest/scripts/cli/test_interfaces_bonding.py @@ -22,7 +22,7 @@ from base_interfaces_test import BasicInterfaceTest from vyos.ifconfig import Section from vyos.ifconfig.interface import Interface from vyos.configsession import ConfigSessionError -from vyos.util import get_json_iface_options +from vyos.util import get_interface_config from vyos.util import read_file class BondingInterfaceTest(BasicInterfaceTest.BaseTest): @@ -105,7 +105,7 @@ class BondingInterfaceTest(BasicInterfaceTest.BaseTest): # verify config for interface in self._interfaces: - tmp = get_json_iface_options(interface) + tmp = get_interface_config(interface) self.assertEqual(min_links, tmp['linkinfo']['info_data']['min_links']) # check LACP default rate @@ -124,7 +124,7 @@ class BondingInterfaceTest(BasicInterfaceTest.BaseTest): # verify config for interface in self._interfaces: - tmp = get_json_iface_options(interface) + tmp = get_interface_config(interface) # check LACP minimum links (default value) self.assertEqual(0, tmp['linkinfo']['info_data']['min_links']) diff --git a/smoketest/scripts/cli/test_interfaces_macsec.py b/smoketest/scripts/cli/test_interfaces_macsec.py index 2f1898b6f..31071a0f7 100755 --- a/smoketest/scripts/cli/test_interfaces_macsec.py +++ b/smoketest/scripts/cli/test_interfaces_macsec.py @@ -25,7 +25,7 @@ from vyos.configsession import ConfigSessionError from vyos.ifconfig import Section from vyos.util import cmd from vyos.util import read_file -from vyos.util import get_json_iface_options +from vyos.util import get_interface_config from vyos.util import process_named_running def get_config_value(interface, key): @@ -34,7 +34,7 @@ def get_config_value(interface, key): return tmp[0] def get_cipher(interface): - tmp = get_json_iface_options(interface) + tmp = get_interface_config(interface) return tmp['linkinfo']['info_data']['cipher_suite'].lower() class MACsecInterfaceTest(BasicInterfaceTest.BaseTest): diff --git a/smoketest/scripts/cli/test_interfaces_tunnel.py b/smoketest/scripts/cli/test_interfaces_tunnel.py index 5ed2c924d..0c562b7d9 100755 --- a/smoketest/scripts/cli/test_interfaces_tunnel.py +++ b/smoketest/scripts/cli/test_interfaces_tunnel.py @@ -18,7 +18,7 @@ import unittest from vyos.configsession import ConfigSession from vyos.configsession import ConfigSessionError -from vyos.util import get_json_iface_options +from vyos.util import get_interface_config from vyos.template import inc_ip from vyos.util import cmd @@ -87,7 +87,7 @@ class TunnelInterfaceTest(BasicInterfaceTest.BaseTest): # Check if commit is ok self.session.commit() - conf = get_json_iface_options(interface) + conf = get_interface_config(interface) if encapsulation not in ['sit', 'gre-bridge']: self.assertEqual(source_if, conf['link']) @@ -128,7 +128,7 @@ class TunnelInterfaceTest(BasicInterfaceTest.BaseTest): # Check if commit is ok self.session.commit() - conf = get_json_iface_options(interface) + conf = get_interface_config(interface) self.assertEqual(interface, conf['ifname']) self.assertEqual(mtu, conf['mtu']) self.assertEqual(source_if, conf['link']) @@ -185,7 +185,7 @@ class TunnelInterfaceTest(BasicInterfaceTest.BaseTest): # Check if commit is ok self.session.commit() - conf = get_json_iface_options(interface) + conf = get_interface_config(interface) self.assertEqual(mtu, conf['mtu']) self.assertEqual(interface, conf['ifname']) self.assertEqual(encapsulation, conf['linkinfo']['info_kind']) @@ -206,7 +206,7 @@ class TunnelInterfaceTest(BasicInterfaceTest.BaseTest): # Check if commit is ok self.session.commit() - conf = get_json_iface_options(interface) + conf = get_interface_config(interface) self.assertEqual(mtu, conf['mtu']) self.assertEqual(interface, conf['ifname']) self.assertEqual('gretap', conf['linkinfo']['info_kind']) @@ -220,7 +220,7 @@ class TunnelInterfaceTest(BasicInterfaceTest.BaseTest): # Check if commit is ok self.session.commit() - conf = get_json_iface_options(interface) + conf = get_interface_config(interface) self.assertEqual(new_remote, conf['linkinfo']['info_data']['remote']) if __name__ == '__main__': |