- (pg_if.name, payload_info.src, packet_index))
- next_info = self.get_next_packet_info_for_interface2(
- payload_info.src, dst_sw_if_index,
- last_info[payload_info.src])
- last_info[payload_info.src] = next_info
- self.assertTrue(next_info is not None)
- self.assertEqual(packet_index, next_info.index)
- saved_packet = next_info.data
- # Check standard fields
- self.assertEqual(ip.src, saved_packet[IP].src)
- self.assertEqual(ip.dst, saved_packet[IP].dst)
- self.assertEqual(udp.sport, saved_packet[UDP].sport)
- self.assertEqual(udp.dport, saved_packet[UDP].dport)
+ (dst_if.name, info.src, info.index))
+ last_info[info.src] = self.get_next_packet_info_for_interface2(
+ info.src, dst, last_info[info.src])
+ pkt_info = last_info[info.src]
+ self.assertTrue(pkt_info is not None)
+ self.assertEqual(info.index, pkt_info.index)
+ # Check standard fields against saved data in pkt
+ saved = pkt_info.data
+ self.assertEqual(ip.src, saved[IP].src)
+ self.assertEqual(ip.dst, saved[IP].dst)
+ self.assertEqual(udp.sport, saved[UDP].sport)
+ self.assertEqual(udp.dport, saved[UDP].dport)