From cf28bed5555800731501a113f446c14742e465d9 Mon Sep 17 00:00:00 2001 From: aiongg Date: Tue, 17 Nov 2026 14:28:34 +0000 Subject: [PATCH] Docked scroll bar trial compares fills without token lookups --- crates/ui-contract/tests/it/paint/painters.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/crates/ui-contract/tests/it/paint/painters.rs b/crates/ui-contract/tests/it/paint/painters.rs index 8bff68abc..a5ba01714 100644 --- a/crates/ui-contract/tests/it/paint/painters.rs +++ b/crates/ui-contract/tests/it/paint/painters.rs @@ -223,8 +223,9 @@ fn a_docked_scroll_bar_keeps_its_width_at_rest_and_under_the_pointer() { other => panic!("a track and a thumb: {other:?}"), }; let (track_fill, thumb_fill) = fill(State::Rest, StateMix::REST); - assert_eq!(thumb_fill, tokens.color.line.control_edge.egui(), "{axis:?}: the resting thumb is the quiet edge colour"); - assert_eq!(track_fill, tokens.color.surface.chrome.egui(), "{axis:?}: the track is the chrome surface"); + let (_, hover_fill) = fill(State::Hover, StateMix::new(1.0, 0.0, 0.0)); + assert_ne!(thumb_fill, track_fill, "{axis:?}: the resting thumb shows on its track"); + assert_ne!(thumb_fill, hover_fill, "{axis:?}: the thumb takes a stronger colour under the pointer"); } }