mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-02 10:18:25 +00:00
Improve core::array
coverage
This commit is contained in:
parent
565a9ca63e
commit
a7528e7ec3
@ -717,3 +717,10 @@ fn array_map_drops_unmapped_elements_on_panic() {
|
||||
assert_eq!(counter.load(Ordering::SeqCst), MAX);
|
||||
}
|
||||
}
|
||||
|
||||
// This covers the `PartialEq::<[T]>::eq` impl for `[T; N]` when it returns false.
|
||||
#[test]
|
||||
fn array_eq() {
|
||||
let not_true = [0u8] == [].as_slice();
|
||||
assert!(!not_true);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user