From f3c9fb3c3c3f77b64ac6b72bda7b9a3ecd25ffc6 Mon Sep 17 00:00:00 2001 From: Brandon Thomas Date: Fri, 9 Oct 2026 13:16:18 -0400 Subject: [PATCH] Tests: pin the session clock in the bookmark-search test, whose two full saves differed when a second ticked between them save_full_bytes stamps /ModDate from the session clock, so the 'search doesn't edit the PDF' comparison failed whenever the two saves straddled a second boundary (seen under a loaded full workspace run). Co-Authored-By: Claude Opus 5.5 --- crates/ui-egui/tests/bookmarks.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/ui-egui/tests/bookmarks.rs b/crates/ui-egui/tests/bookmarks.rs index 0477c306f..2d2b3d2c2 100644 --- a/crates/ui-egui/tests/bookmarks.rs +++ b/crates/ui-egui/tests/bookmarks.rs @@ -145,6 +145,9 @@ fn search_finds_collapsed_bookmarks_and_keeps_original_paths() { h.run_steps(3); assert!(h.query_by_label("Résumé results").is_none()); let id = h.state().views[0].id; + // A full save stamps /ModDate from the clock: pin it, or two saves a second apart differ. + let session = std::mem::take(&mut h.state_mut().session); + h.state_mut().session = session.with_clock(|| 1_700_000_000); let before = h.state().session.save_full_bytes(id).unwrap(); h.get_by_label("Search").click(); h.run_steps(1);