From bf37300a17fc89165cf5f8c5bd0dd07b30b77e8f Mon Sep 17 00:00:00 2001 From: aiongg Date: Sun, 22 Nov 2026 02:19:01 +0000 Subject: [PATCH] ToggleCell: the empty_off test lives in the layers panel_eye trial (design-lint: no cfg(test) module in an egui-linked crate) --- crates/ui-widgets/src/list/toggle.rs | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/crates/ui-widgets/src/list/toggle.rs b/crates/ui-widgets/src/list/toggle.rs index 82f8f8149..afe5733a2 100644 --- a/crates/ui-widgets/src/list/toggle.rs +++ b/crates/ui-widgets/src/list/toggle.rs @@ -185,18 +185,3 @@ impl ToggleCell { !self.empty_off && (self.always_visible || hovered) } } - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn an_empty_off_cell_never_draws_its_off_icon() { - let eye = ToggleCell::eye(ColumnKey::new("eye"), false); - assert!(!eye.shows_off(false) && eye.shows_off(true), "a plain off cell shows its off icon only under the pointer"); - assert!(eye.clone().always_visible().shows_off(false), "always_visible shows it in every row"); - let empty = eye.empty_off(); - assert!(!empty.shows_off(true), "an empty_off cell stays empty under the pointer"); - assert!(!empty.always_visible().shows_off(true), "empty_off wins over always_visible"); - } -}