From 31da2e30317bc1fcb4586e1dc0d560600d9b29d3 Mon Sep 17 00:00:00 2001 From: Klement Sekera Date: Sun, 24 Jun 2018 22:49:55 +0200 Subject: Revert "Revert "ipsec: VPP-1316 calculate IP/TCP/UDP inner checksums"" This reverts commit e0d2bd6bd7fc59c0c6ac48195d7f825dc99bfd91. Change-Id: If491e16f9ea66b2493a6a7c7f3c684ed585f8f51 Signed-off-by: Klement Sekera --- test/vpp_tunnel_interface.py | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 test/vpp_tunnel_interface.py (limited to 'test/vpp_tunnel_interface.py') diff --git a/test/vpp_tunnel_interface.py b/test/vpp_tunnel_interface.py new file mode 100644 index 00000000000..c74f58532f2 --- /dev/null +++ b/test/vpp_tunnel_interface.py @@ -0,0 +1,32 @@ +from abc import abstractmethod, ABCMeta +from vpp_pg_interface import is_ipv6_misc +from vpp_interface import VppInterface + + +class VppTunnelInterface(VppInterface): + """ VPP tunnel interface abstration """ + __metaclass__ = ABCMeta + + @abstractmethod + def __init__(self, test, parent_if): + super(VppTunnelInterface, self).__init__(test) + self.parent_if = parent_if + + @property + def local_mac(self): + return self.parent_if.local_mac + + @property + def remote_mac(self): + return self.parent_if.remote_mac + + def enable_capture(self): + return self.parent_if.enable_capture() + + def add_stream(self, pkts): + return self.parent_if.add_stream(pkts) + + def get_capture(self, expected_count=None, remark=None, timeout=1, + filter_out_fn=is_ipv6_misc): + return self.parent_if.get_capture(expected_count, remark, timeout, + filter_out_fn) -- cgit 1.2.3-korg