From 4f70ebf481d496f91d2b1ec27361c9898b19c451 Mon Sep 17 00:00:00 2001 From: selias Date: Fri, 25 Nov 2016 10:50:29 +0100 Subject: CSIT-481: HC Test: Port mirroring (SPAN) - add port mirroring test suite - add relevant keywords Change-Id: I4ff398dd2ab4323e2a53af2812bf07cbb7043252 Signed-off-by: selias --- resources/libraries/python/topology.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'resources/libraries/python/topology.py') diff --git a/resources/libraries/python/topology.py b/resources/libraries/python/topology.py index 3c903e5c94..0214cc9c02 100644 --- a/resources/libraries/python/topology.py +++ b/resources/libraries/python/topology.py @@ -125,6 +125,19 @@ class Topology(object): """ node['interfaces'][iface_key]['vpp_sw_index'] = int(sw_if_index) + @staticmethod + def update_interface_name(node, iface_key, name): + """Update name on the interface from the node. + + :param node: Node to update name on. + :param iface_key: Topology key of the interface. + :param name: Interface name to store. + :type node: dict + :type iface_key: str + :type name: str + """ + node['interfaces'][iface_key]['name'] = str(name) + @staticmethod def update_interface_mac_address(node, iface_key, mac_address): """Update mac_address on the interface from the node. -- cgit 1.2.3-korg