1
0
mirror of https://github.com/emilk/egui.git synced 2026-09-01 06:10:06 -04:00
This commit is contained in:
lucasmerlin
2026-03-20 10:25:19 +01:00
parent f1392b1490
commit 08bf4c2d53
2 changed files with 6 additions and 8 deletions

View File

@@ -332,10 +332,7 @@ mod id_source {
let nested = Id::new(parent).with(child); let nested = Id::new(parent).with(child);
assert_eq!(format!("{parent:?}"), r#"9DE0 ("parent")"#); assert_eq!(format!("{parent:?}"), r#"9DE0 ("parent")"#);
assert_eq!( assert_eq!(format!("{child:?}"), r#"F27D ("child") <- 9DE0 ("parent")"#);
format!("{child:?}"),
r#"F27D ("child") <- 9DE0 ("parent")"#
);
assert_eq!( assert_eq!(
format!("{nested:?}"), format!("{nested:?}"),
r#"A8BE(F27D ("child") <- 9DE0 ("parent")) <- B20C(9DE0 ("parent"))"# r#"A8BE(F27D ("child") <- 9DE0 ("parent")) <- B20C(9DE0 ("parent"))"#

View File

@@ -1,4 +1,4 @@
use egui::{include_image, Id, Modifiers, ScrollArea, Vec2}; use egui::{Id, Modifiers, ScrollArea, Vec2, include_image};
use egui_kittest::{Harness, SnapshotResults}; use egui_kittest::{Harness, SnapshotResults};
use kittest::Queryable as _; use kittest::Queryable as _;
@@ -197,12 +197,13 @@ fn test_id_popup() {
id.ui(ui); id.ui(ui);
}); });
harness
harness.get_by_label_contains(&id.short_debug_format()).hover(); .get_by_label_contains(&id.short_debug_format())
.hover();
harness.run(); harness.run();
harness.fit_contents(); harness.fit_contents();
results.add(harness.try_snapshot(format!("id_popup_{}", idx))); results.add(harness.try_snapshot(format!("id_popup_{idx}")));
} }
} }