mirror of
https://github.com/storytold/wordcraft.git
synced 2026-11-18 00:15:44 +00:00
Test: assert egui popup state on font arrow toggle (#6722)
This commit is contained in:
1 parent
0909b15eae
commit
7bff3b53e9
1 file changed
+2
@@ -551,9 +551,11 @@ fn clicking_the_font_arrow_toggles_dropdown_and_preserves_caret_on_field_click()
|
||||
h.event(egui::Event::Text("!".into()));
|
||||
h.run_steps(2);
|
||||
assert_eq!(h.get(By::new().role(Role::TextInput)).value().as_deref(), Some("Times New !Roman"));
|
||||
assert!(egui::Popup::is_any_open(&h.ctx), "dropdown popup stays open even with no matches");
|
||||
|
||||
h.get(By::new().role(Role::Button).label_contains("Font options")).click();
|
||||
h.run_steps(2);
|
||||
assert!(!egui::Popup::is_any_open(&h.ctx), "dropdown popup closes on arrow click toggle");
|
||||
assert!(h.query_by_label("All Fonts").is_none(), "dropdown closes on arrow click toggle");
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user