diff options
author | Matej Klotton <mklotton@cisco.com> | 2016-11-04 11:11:44 +0100 |
---|---|---|
committer | Damjan Marion <dmarion.lists@gmail.com> | 2016-11-11 10:29:04 +0000 |
commit | 0178d52384e0428368f1acf3163e664ecda7b64c (patch) | |
tree | 8f6e09a23ca9b332df92f0ac16cc7d2526d7e4b6 /test/util.py | |
parent | 9db551cf50da13bf82d3a735ea6b56912a97d5c6 (diff) |
Add IRB test
- JIRA: CSIT-255
- create loopback interfaces
- move pg-interface specific arp and neighbor discovery from vpp_interface to vpp_pg_interface
- base configuration of IRB tests
- IP test scenario
Change-Id: I9945a188163652a4e22325877aef008c4d029557
Signed-off-by: Matej Klotton <mklotton@cisco.com>
Diffstat (limited to 'test/util.py')
-rw-r--r-- | test/util.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/test/util.py b/test/util.py index 8d7c9202a41..6e7e275cddc 100644 --- a/test/util.py +++ b/test/util.py @@ -1,8 +1,7 @@ -from logging import * +import socket - -class TestHost(object): - """ Generic test host "connected" to VPP. """ +class Host(object): + """ Generic test host "connected" to VPPs interface. """ @property def mac(self): @@ -15,6 +14,11 @@ class TestHost(object): return self._ip4 @property + def ip4n(self): + """ IPv4 address """ + return socket.inet_pton(socket.AF_INET, self._ip4) + + @property def ip6(self): """ IPv6 address """ return self._ip6 |