update gen_testdata
- add more packets - fix counter for one packet
This commit is contained in:
parent
71c842576a
commit
86885760b2
5 changed files with 114 additions and 9 deletions
|
|
@ -101,6 +101,7 @@ lookup_table = {
|
|||
}
|
||||
|
||||
def test_port1():
|
||||
""" packets for a certain mac always go to nf0 """
|
||||
pktCnt = 0
|
||||
|
||||
# First ethernet
|
||||
|
|
@ -108,6 +109,14 @@ def test_port1():
|
|||
pkt = Ether(dst=MAC2, src=MAC1)
|
||||
pkt = pad_pkt(pkt, 64)
|
||||
applyPkt(pkt, 'nf0', pktCnt)
|
||||
|
||||
pktCnt += 1
|
||||
expPkt(pkt, 'nf0')
|
||||
|
||||
pktCnt += 1
|
||||
applyPkt(pkt, 'nf1', pktCnt)
|
||||
|
||||
pktCnt += 1
|
||||
expPkt(pkt, 'nf0')
|
||||
|
||||
# Test that packets are being mirrored
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue