[domistream] Tests: first compile, clippy clean
Temporaries borrowed past their statement (control, media), clippy's is_multiple_of, needless index loop and type complexity. input.rs: the MOUSE_MOVE_ABS builder dropped the y field; the PROTOCOL.md cross-check would have caught it at runtime.
This commit is contained in:
@@ -60,7 +60,8 @@ fn video_packet_fields() {
|
||||
// Parity shard 5 of 4 + 2 is in range.
|
||||
assert!(parse_video_packet(&video_packet_bytes(1, 0, 0, 0, 0, fec_info(50, 5, 4), &payload)).is_ok());
|
||||
// Bits 0-3 of fecInfo are not part of any field.
|
||||
let v = parse_video_packet(&video_packet_bytes(1, 0, 0, 1, 0, fec_info(50, 0, 4) | 0xF, &payload)).unwrap();
|
||||
let p = video_packet_bytes(1, 0, 0, 1, 0, fec_info(50, 0, 4) | 0xF, &payload);
|
||||
let v = parse_video_packet(&p).unwrap();
|
||||
assert_eq!((v.nv.fec.shard_index, v.nv.fec.data_shards, v.nv.fec.fec_percentage), (0, 4, 50));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user