mirror of
https://github.com/storytold/filmcraft.git
synced 2026-10-14 19:26:59 -04:00
chrome_ui test: the menu bar's automation ids (menu.*, from #454) sit in the header
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
814287858c
commit
adcd28b11a
1 file changed
+2
-2
@@ -24,10 +24,10 @@ fn harness(show_header: bool, show_status_bar: bool) -> Harness<'static, Filmcra
|
||||
harness
|
||||
}
|
||||
|
||||
/// Top and bottom edge of every registered element outside the header.
|
||||
/// Top and bottom edge of every registered element outside the header (the menu bar, `menu.*`, is part of it).
|
||||
fn body_extent(h: &Harness<'static, FilmcraftApp>) -> (f32, f32) {
|
||||
let els = h.state().auto.query("");
|
||||
let body: Vec<_> = els.iter().filter(|e| !e.id.starts_with("header.")).collect();
|
||||
let body: Vec<_> = els.iter().filter(|e| !e.id.starts_with("header.") && !e.id.starts_with("menu.")).collect();
|
||||
assert!(!body.is_empty(), "no panel elements registered");
|
||||
let top = body.iter().map(|e| e.rect[1]).fold(f32::INFINITY, f32::min);
|
||||
let bottom = body.iter().map(|e| e.rect[1] + e.rect[3]).fold(f32::NEG_INFINITY, f32::max);
|
||||
|
||||
Reference in new issue
Block a user