aboutsummaryrefslogtreecommitdiffstats
path: root/test/framework.py
diff options
context:
space:
mode:
authorOle Troan <ot@cisco.com>2018-06-22 22:33:41 +0200
committerOle Troan <ot@cisco.com>2018-06-22 22:34:56 +0200
commitc8efa29b6f9a91381897b54f1147daf922ed7164 (patch)
tree405258dffbc11e9c29ca10fc8c734ec311a374b4 /test/framework.py
parentd5c60b96a3fd93916fc4af5c8d6d25625c28242e (diff)
Revert "make test: fix broken interfaces"
This reverts commit d5c60b96a3fd93916fc4af5c8d6d25625c28242e. Change-Id: I3632b9c3f76c615aee897f28f76d094e7031e689 Signed-off-by: Ole Troan <ot@cisco.com>
Diffstat (limited to 'test/framework.py')
-rw-r--r--test/framework.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/test/framework.py b/test/framework.py
index dd4774dc72b..be8c209f4ea 100644
--- a/test/framework.py
+++ b/test/framework.py
@@ -558,16 +558,18 @@ class VppTestCase(unittest.TestCase):
return result
@classmethod
- def create_loopback_interfaces(cls, count):
+ def create_loopback_interfaces(cls, interfaces):
"""
Create loopback interfaces.
- :param count: number of interfaces created.
+ :param interfaces: iterable indexes of the interfaces.
:returns: List of created interfaces.
"""
- result = [VppLoInterface(cls) for i in range(count)]
- for intf in result:
+ result = []
+ for i in interfaces:
+ intf = VppLoInterface(cls, i)
setattr(cls, intf.name, intf)
+ result.append(intf)
cls.lo_interfaces = result
return result