geneve: Fix the byte swapping for the VNI

Type: fix

- swipe away the vomit indent left last time.
- add tests for VNIs > 16bit

Change-Id: I2d1f591bfb9d7a18996c38969365a509168d4193
Signed-off-by: Neale Ranns <nranns@cisco.com>
This commit is contained in:
Neale Ranns
2020-04-03 07:46:28 +00:00
committed by Damjan Marion
parent ae9c45938b
commit 91fd910d7d
10 changed files with 66 additions and 80 deletions

View File

@ -74,7 +74,7 @@ class BridgeDomain(object):
"""
encapsulated_pkt = self.encapsulate(self.frame_request,
self.single_tunnel_bd)
self.single_tunnel_vni)
self.pg0.add_stream([encapsulated_pkt, ])
@ -102,7 +102,7 @@ class BridgeDomain(object):
# Pick first received frame and check if it's correctly encapsulated.
out = self.pg0.get_capture(1)
pkt = out[0]
self.check_encapsulation(pkt, self.single_tunnel_bd)
self.check_encapsulation(pkt, self.single_tunnel_vni)
payload = self.decapsulate(pkt)
self.assert_eq_pkts(payload, self.frame_reply)