diff --git a/src/component.rs b/src/component.rs index d02ff75..8e5faca 100644 --- a/src/component.rs +++ b/src/component.rs @@ -286,9 +286,8 @@ impl Drop for TestComponent { // while panicking" even when nobody asks for it (RUST_BACKTRACE unset). Let the error // appear if there isn't any other error. if !thread::panicking() { - assert_eq!( - self.expect_buffer.len(), - 0, + assert!( + self.expect_buffer.is_empty(), "Remaining expected elements in the buffer" ); }