pub fn assert_contains<H, N>(needle: N, haystack: H)where H: Container + Debug, N: Borrow<H::Item>, H::Item: Debug,
Assert that a haystack contains the given needle.
Uses the Container abstraction so it works with slices, vectors, sets, maps (by key), strings, and ranges. The error message includes both the container and the item for quick debugging.
Container
Panics if haystack.contains(needle) returns false.
haystack.contains(needle)