From 2918106ecbb96baa7217fbd99be18f9469f7ff7e Mon Sep 17 00:00:00 2001 From: Lilith River Date: Sat, 7 Feb 2026 17:42:25 -0700 Subject: [PATCH] fix: correct test_fmt expectations in v08.rs - Add u8 suffix to prevent i32 inference (wrong hex width) - Fix expected hex format to match actual UpperHex impl (#RRGGBB, no type name wrapper) - BGR hex output matches RGB order, consistent with passing internal test --- tests/v08.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/v08.rs b/tests/v08.rs index 01485283..2be28231 100644 --- a/tests/v08.rs +++ b/tests/v08.rs @@ -400,13 +400,13 @@ mod rgb_test { #[test] #[allow(deprecated)] fn test_fmt() { - let red_rgb = RGB::new(255, 0, 0); - let red_bgr = BGR::new(255, 0, 0); - assert_eq!("RGB { #FF0000 }", &format!("{red_rgb:X}")); - assert_eq!("BGR { #0000FF }", &format!("{red_bgr:X}")); + let red_rgb = RGB::new(255u8, 0, 0); + let red_bgr = BGR::new(255u8, 0, 0); + assert_eq!("#FF0000", &format!("{red_rgb:X}")); + assert_eq!("#FF0000", &format!("{red_bgr:X}")); - assert_eq!("RGB { #ff0000 }", &format!("{red_rgb:x}")); - assert_eq!("BGR { #0000ff }", &format!("{red_bgr:x}")); + assert_eq!("#ff0000", &format!("{red_rgb:x}")); + assert_eq!("#ff0000", &format!("{red_bgr:x}")); assert_eq!("rgb(255,0,0)", &format!("{red_rgb}")); assert_eq!("bgr(0,0,255)", &format!("{red_bgr}"));