assertions: use assert_eq! where possible

Using `assert_eq!` instead of `assert!` has the advantage that when the
assertion fails, the debug representation of both sides will be shown,
which can provide more information about the failure than only seeing
that the assertion failed.

Part of #12336
This commit is contained in:
Daniel Rainer
2026-01-16 19:12:12 +01:00
committed by Johannes Altmanninger
parent 939fa25a5b
commit 8718d62b11
33 changed files with 138 additions and 99 deletions

View File

@@ -84,7 +84,7 @@ macro_rules! sprintf {
///
/// let result = printf_c_locale(&mut output, fmt, &mut args);
///
/// assert!(result == Ok(10));
/// assert_eq!(result, Ok(10));
/// assert_eq!(output, "1.2346e+05");
/// ```
pub fn printf_c_locale(