From 7f754fc9fd82e55d12d7778e8c23a9446705a575 Mon Sep 17 00:00:00 2001 From: Richard Buschbeck Date: Fri, 13 Nov 2026 11:40:55 +0100 Subject: [PATCH] test(ui): run the Home recent Reveal test inline so its toast check can't race home_recent_context_menu_reveals_the_target_without_opening_or_removing_it never set run_inline, so reveal_path checked the missing file on a pdfcraft-reveal worker thread while the test waited a fixed three frames before asserting the "The file no longer exists" toast. On a loaded runner the worker can report after those frames and the assertion fails. Set run_inline, as the reveal unit test in tab_context.rs already does. --- crates/ui-egui/tests/it/ui.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/ui-egui/tests/it/ui.rs b/crates/ui-egui/tests/it/ui.rs index c53c1c9c50..9363737413 100644 --- a/crates/ui-egui/tests/it/ui.rs +++ b/crates/ui-egui/tests/it/ui.rs @@ -2144,6 +2144,9 @@ fn home_recent_context_menu_reveals_the_target_without_opening_or_removing_it() let mut h = Harness::builder().with_size(egui::vec2(1400.0, 1600.0)).build_eframe(move |_| { let mut app = PdfCraftApp::new(); app.set_option("language", "en").unwrap(); + // The existence check runs on a worker otherwise, which can lose the race with the + // fixed frame count below on a busy runner. + app.run_inline = true; for (name, path) in [("first.pdf", ".".to_owned()), ("target.pdf", target)] { app.recent.push(pdfcraft_ui_egui::RecentFile { name: name.into(), path, pages: 1, size: 0 }); }