summaryrefslogtreecommitdiffstats
path: root/test/test_udp.py
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2018-02-23 05:29:09 -0800
committerDamjan Marion <dmarion.lists@gmail.com>2018-03-09 11:59:58 +0000
commit31ed74407643595fdce206e9d7487108fb8b33ab (patch)
treec22c3703c30b7d457b858fe899f56e57613cbb52 /test/test_udp.py
parent8f931a47b0fa58d5d33a792062650a42ff8bef70 (diff)
MPLS Unifom mode
- support both pipe and uniform modes for all MPLS LSP - all API programming for output-labels requires that the mode (and associated data) is specificed - API changes in MPLS, BIER and IP are involved - new DPO [sub] types for MPLS labels to handle the two modes. Change-Id: I87b76401e996f10dfbdbe4552ff6b19af958783c Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'test/test_udp.py')
-rw-r--r--test/test_udp.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/test_udp.py b/test/test_udp.py
index 68b023c5e2f..322d8133b0d 100644
--- a/test/test_udp.py
+++ b/test/test_udp.py
@@ -2,7 +2,7 @@
from framework import VppTestCase, VppTestRunner
from vpp_udp_encap import *
-from vpp_ip_route import VppIpRoute, VppRoutePath, VppIpTable
+from vpp_ip_route import VppIpRoute, VppRoutePath, VppIpTable, VppMplsLabel
from scapy.packet import Raw
from scapy.layers.l2 import Ether, ARP
@@ -67,12 +67,12 @@ class TestUdpEncap(VppTestCase):
self.assertEqual(rx[UDP].dport, encap_obj.dst_port)
def validate_inner4(self, rx, tx, ttl=None):
- self.assertEqual(rx.src, tx[IP].src)
- self.assertEqual(rx.dst, tx[IP].dst)
+ self.assertEqual(rx[IP].src, tx[IP].src)
+ self.assertEqual(rx[IP].dst, tx[IP].dst)
if ttl:
- self.assertEqual(rx.ttl, ttl)
+ self.assertEqual(rx[IP].ttl, ttl)
else:
- self.assertEqual(rx.ttl, tx[IP].ttl)
+ self.assertEqual(rx[IP].ttl, tx[IP].ttl)
def validate_inner6(self, rx, tx):
self.assertEqual(rx.src, tx[IPv6].src)
@@ -208,7 +208,7 @@ class TestUdpEncap(VppTestCase):
0xFFFFFFFF,
is_udp_encap=1,
next_hop_id=1,
- labels=[66])])
+ labels=[VppMplsLabel(66)])])
route_4oMPLSo4.add_vpp_config()
p_4omo4 = (Ether(src=self.pg0.remote_mac,