From 1e3ab306d4f999c41529264eaf53fad3b3bc5d64 Mon Sep 17 00:00:00 2001 From: bflatastic Date: Sun, 18 Oct 2026 12:43:56 +0700 Subject: [PATCH] Tests: the dropdown keyboard test clears the texture updates it doesn't apply (#2824) --- crates/ui-egui/src/widgets.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crates/ui-egui/src/widgets.rs b/crates/ui-egui/src/widgets.rs index db80bce74..13d64a816 100644 --- a/crates/ui-egui/src/widgets.rs +++ b/crates/ui-egui/src/widgets.rs @@ -2613,11 +2613,13 @@ mod combo_keyboard_tests { } fn frame(ctx: &egui::Context, events: Vec, picked: &mut Option) { - let _ = ctx.run_ui(egui::RawInput { events, ..Default::default() }, |ui| { + let mut out = ctx.run_ui(egui::RawInput { events, ..Default::default() }, |ui| { if let Some(i) = dropdown(ui, "combo-test", "One", &["One", "Two", "Three"], 200.0) { *picked = Some(i); } }); + // No renderer takes the font atlas updates in a test; dropping them unapplied panics. + out.textures_delta.clear(); } /// An option picked with the keyboard closes the list (it used to stay open and keep the keys).