aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/test_srv6_mobile.py27
1 files changed, 17 insertions, 10 deletions
diff --git a/test/test_srv6_mobile.py b/test/test_srv6_mobile.py
index a695c9d7115..e617acef9ab 100644
--- a/test/test_srv6_mobile.py
+++ b/test/test_srv6_mobile.py
@@ -69,9 +69,10 @@ class TestSRv6EndMGTP4E(VppTestCase):
pkts = self.create_packets([("A::1", "B::1"), ("C::1", "D::1")])
self.vapi.cli(
- "sr localsid address {} behavior end.m.gtp4.e v4src_position 64"
- .format(pkts[0]['IPv6'].dst))
- self.logger.info(self.vapi.cli("show sr localsids"))
+ "sr localsid address {} behavior end.m.gtp4.e "
+ .format(pkts[0]['IPv6'].dst) +
+ "v4src_position 64 fib-table 0")
+ self.logger.info(self.vapi.cli("show sr localsid"))
self.vapi.cli("clear errors")
@@ -150,8 +151,8 @@ class TestSRv6TMGTP4D(VppTestCase):
self.vapi.cli("set sr encaps source addr A1::1")
self.vapi.cli("sr policy add bsid D4:: next D2:: next D3::")
self.vapi.cli(
- "sr policy add bsid D5:: behavior t.m.gtp4.d"
- "D4::/32 v6src_prefix C1::/64 nhtype ipv6")
+ "sr policy add bsid D5:: behavior t.m.gtp4.d D4::/32 " +
+ "v6src_prefix C1::/64 nhtype ipv6 fib-table 0 drop-in")
self.vapi.cli("sr steer l3 {}/32 via bsid D5::".format(self.ip4_dst))
self.vapi.cli("ip route add D2::/32 via {}".format(self.ip6_dst))
@@ -236,11 +237,11 @@ class TestSRv6EndMGTP6E(VppTestCase):
pkts = self.create_packets([("A::1", "B::1"), ("C::1", "D::1")])
self.vapi.cli(
- "sr localsid prefix {}/64 behavior end.m.gtp6.e"
+ "sr localsid prefix {}/64 behavior end.m.gtp6.e fib-table 0"
.format(pkts[0]['IPv6'].dst))
self.vapi.cli(
"ip route add a1::/64 via {}".format(self.ip6_nhop))
- self.logger.info(self.vapi.cli("show sr localsids"))
+ self.logger.info(self.vapi.cli("show sr localsid"))
self.vapi.cli("clear errors")
@@ -316,10 +317,12 @@ class TestSRv6EndMGTP6D(VppTestCase):
self.vapi.cli("set sr encaps source addr A1::1")
self.vapi.cli("sr policy add bsid D4:: next D2:: next D3::")
self.vapi.cli(
- "sr localsid prefix 2001::/64 behavior end.m.gtp6.d D4::/64")
+ "sr localsid prefix 2001::/64 behavior end.m.gtp6.d " +
+ "D4::/64 fib-table 0 drop-in")
self.vapi.cli("ip route add D2::/64 via {}".format(self.ip6_nhop))
self.logger.info(self.vapi.cli("show sr policies"))
+ self.logger.info(self.vapi.cli("show sr localsid"))
self.vapi.cli("clear errors")
@@ -334,7 +337,11 @@ class TestSRv6EndMGTP6D(VppTestCase):
for pkt in capture:
self.logger.info(pkt.show2(dump=True))
- self.logger.info("GTP6.D Address={}".format(
+ self.logger.info("GTP6.D SID0={}".format(
str(pkt[IPv6ExtHdrSegmentRouting].addresses[0])))
+ self.logger.info("GTP6.D SID1={}".format(
+ str(pkt[IPv6ExtHdrSegmentRouting].addresses[1])))
+ self.assertEqual(
+ str(pkt[IPv6ExtHdrSegmentRouting].addresses[0]), "2001::1")
self.assertEqual(
- str(pkt[IPv6ExtHdrSegmentRouting].addresses[0]), "d4::c800:0")
+ str(pkt[IPv6ExtHdrSegmentRouting].addresses[1]), "d4::c800:0")