some clippy improvements

This commit is contained in:
Robin Müller 2024-02-17 00:00:57 +01:00
parent 8c23a9c924
commit 359e5124bd
Signed by: muellerr
GPG Key ID: A649FB78196E3849

View File

@ -541,9 +541,9 @@ pub mod tests {
u8.write_to_be_bytes(&mut buf)
.expect("writing to raw buffer failed");
assert_eq!(buf[0], 5);
for i in 1..8 {
(1..8).for_each(|i| {
assert_eq!(buf[i], 0);
}
});
}
#[test]
@ -569,9 +569,9 @@ pub mod tests {
.expect("writing to raw buffer failed");
let raw_val = u32::from_be_bytes(buf[0..4].try_into().unwrap());
assert_eq!(raw_val, 80932);
for i in 4..8 {
(4..8).for_each(|i| {
assert_eq!(buf[i], 0);
}
});
}
#[test]