apply clippy in tests
This commit is contained in:
@@ -46,16 +46,16 @@ mod tests {
|
||||
(3.0, 3.0),
|
||||
(3.5, 4.0),
|
||||
(4.5, 4.0),
|
||||
(4.500001, 5.0),
|
||||
(3.499999, 3.0),
|
||||
(3.500001, 4.0),
|
||||
(4.500_001, 5.0),
|
||||
(3.499_999, 3.0),
|
||||
(3.500_001, 4.0),
|
||||
(100_000_000_002.5, 100_000_000_002.0),
|
||||
(-3.0, -3.0),
|
||||
(-3.5, -4.0),
|
||||
(-4.5, -4.0),
|
||||
(-4.500001, -5.0),
|
||||
(-3.499999, -3.0),
|
||||
(-3.500001, -4.0),
|
||||
(-4.500_001, -5.0),
|
||||
(-3.499_999, -3.0),
|
||||
(-3.500_001, -4.0),
|
||||
(-100_000_000_002.5, -100_000_000_002.0),
|
||||
];
|
||||
|
||||
|
||||
@@ -245,12 +245,12 @@ mod test {
|
||||
|
||||
let (head, tail) = queue.as_slices();
|
||||
|
||||
for i in 0..head.len() {
|
||||
assert_eq!(queue.iter().nth(i), Some(&head[i]));
|
||||
for (i, item) in head.iter().enumerate() {
|
||||
assert_eq!(queue.iter().nth(i), Some(item));
|
||||
}
|
||||
|
||||
for i in 0..tail.len() {
|
||||
assert_eq!(queue.iter().nth(head.len() + i), Some(&tail[i]));
|
||||
for (i, item) in tail.iter().enumerate() {
|
||||
assert_eq!(queue.iter().nth(head.len() + i), Some(item));
|
||||
}
|
||||
|
||||
assert_eq!(queue.iter().nth(head.len() + tail.len() + 1), None);
|
||||
|
||||
Reference in New Issue
Block a user