From 5a5ecaf5d73bda31ff481cbf9d0cb6451ef5fdc9 Mon Sep 17 00:00:00 2001 From: David Mann Date: Thu, 3 Dec 2026 02:12:39 +0100 Subject: [PATCH] test(automation): one lock for the window-requests assertion Co-Authored-By: Claude Opus 5.5 --- crates/automation/src/agents_tests.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/automation/src/agents_tests.rs b/crates/automation/src/agents_tests.rs index 21b7a52a2..c1ddcfcac 100644 --- a/crates/automation/src/agents_tests.rs +++ b/crates/automation/src/agents_tests.rs @@ -182,7 +182,8 @@ fn the_commands_folders_bind_calls_to_the_window_too() { let e = crate::tools::run(&mut b, tool, &args).err().map(|e| e.to_string()).unwrap_or_default(); assert!(e.contains("not available while file access is confined"), "{tool}: {e}"); } - assert_eq!(seen.lock().unwrap().len(), 1, "only the save inside reached the window: {:?}", seen.lock().unwrap()); + let seen = seen.lock().unwrap(); + assert_eq!(seen.len(), 1, "only the save inside reached the window: {seen:?}"); } #[test]