Function itertools::assert_equal
source · pub fn assert_equal<I, J>(a: I, b: J)
Expand description
Assert that two iterables produce equal sequences, with the same
semantics as equal(a, b)
.
Panics on assertion failure with a message that shows the two iteration elements.
ⓘ
assert_equal("exceed".split('c'), "excess".split('c'));
// ^PANIC: panicked at 'Failed assertion Some("eed") == Some("ess") for iteration 1'.