Change testdata offset by 1 and find checksum error

This commit is contained in:
Nico Schottelius 2019-07-13 22:07:53 +02:00
commit a9cc93281e
2 changed files with 143 additions and 32 deletions

View file

@ -106,33 +106,14 @@ def test_port1():
pkt = Ether(dst=MAC2, src=MAC1)
pkt = pad_pkt(pkt, 64)
# Send on nf0
pktCnt += 1
applyPkt(pkt, 'nf0', pktCnt)
for inport in [ 'nf0', 'nf1', 'nf2', 'nf3' ]:
# Send on nf0
applyPkt(pkt, inport, pktCnt)
# Receive on nf0
expPkt(pkt, 'nf0')
# Always receive on nf0
expPkt(pkt, 'nf0')
# Send on nf1
pktCnt += 1
applyPkt(pkt, 'nf1', pktCnt)
# Receive on nf0
expPkt(pkt, 'nf0')
# Send on nf2
pktCnt += 1
applyPkt(pkt, 'nf2', pktCnt)
# Receive on nf0
expPkt(pkt, 'nf0')
# Send on nf3
pktCnt += 1
applyPkt(pkt, 'nf3', pktCnt)
# Receive on nf0
expPkt(pkt, 'nf0')
pktCnt += 1
# Test that packets are being mirrored
def test_mirror():