aboutsummaryrefslogtreecommitdiffstats
path: root/resources/libraries/python
diff options
context:
space:
mode:
authorJan Gelety <jgelety@cisco.com>2017-08-14 09:04:09 +0200
committerJan Gelety <jgelety@cisco.com>2017-08-16 14:39:56 +0200
commita75ddafd4f342b6c7964f0c5b152d0674144e33a (patch)
treef3ee28133f831982a28157cfe011cb60c0debdd3 /resources/libraries/python
parentba0d4b44c16a371f9fd8386121995ce81baa668a (diff)
CSIT-777: L2 keywords for MACIP ACL tests
Change-Id: I678d87770405105555ccc30ce0003f704d7ca82e Signed-off-by: Jan Gelety <jgelety@cisco.com>
Diffstat (limited to 'resources/libraries/python')
-rw-r--r--resources/libraries/python/Classify.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/resources/libraries/python/Classify.py b/resources/libraries/python/Classify.py
index b89a20dd2d..a66994906b 100644
--- a/resources/libraries/python/Classify.py
+++ b/resources/libraries/python/Classify.py
@@ -410,8 +410,10 @@ class Classify(object):
:type acl_idx: list
:raises RuntimeError: If unable to set ACL list for the interface.
"""
- sw_if_index = Topology.get_interface_sw_index(node, interface) \
- if isinstance(interface, basestring) else interface
+ if isinstance(interface, basestring):
+ sw_if_index = Topology.get_interface_sw_index(node, interface)
+ else:
+ sw_if_index = interface
acl_list = acl_type + ' ' + ' '.join(str(idx) for idx in acl_idx) \
if acl_idx else acl_type