Lines Matching refs:packet
42 let packet = Packet::unmarshal(buf)?; in test_basic() localVariable
44 packet, parsed_packet, in test_basic()
48 packet.header.marshal_size(), in test_basic()
53 packet.marshal_size(), in test_basic()
58 let raw = packet.marshal()?; in test_basic()
100 let packet = Packet { in test_extension() localVariable
114 let result = packet.marshal_to(&mut raw); in test_extension()
134 let packet = Packet::unmarshal(buf)?; in test_padding() localVariable
135 assert_eq!(&packet.payload[..], &raw_pkt[12..12 + 25]); in test_padding()
137 let raw = packet.marshal()?; in test_padding()
295 let packet = Packet::unmarshal(buf)?; in test_rfc_8285_one_byte_multiple_extensions_with_padding() localVariable
296 let ext1 = packet in test_rfc_8285_one_byte_multiple_extensions_with_padding()
304 let ext2 = packet in test_rfc_8285_one_byte_multiple_extensions_with_padding()
312 let ext3 = packet in test_rfc_8285_one_byte_multiple_extensions_with_padding()
342 checker("CleanBuffer", &mut dst_buf[0], &packet)?; in test_rfc_8285_one_byte_multiple_extensions_with_padding()
343 checker("DirtyBuffer", &mut dst_buf[1], &packet)?; in test_rfc_8285_one_byte_multiple_extensions_with_padding()
345 let result = packet.marshal_to(&mut dst_buf[2]); in test_rfc_8285_one_byte_multiple_extensions_with_padding()