From 56821949e30f3accbbd198755554a08fdf0ee6d2 Mon Sep 17 00:00:00 2001 From: Anubhav-Rai Date: Thu, 29 Oct 2026 10:30:13 +0530 Subject: [PATCH] automation: the out-of-root proxy path is absolute on Windows too (#2479) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Introduced by the commit before this one. Dropping the `WRITES` entry changed that refusal's wording from `cannot write` to `cannot read`, so the assertion moved to the part both share — `outside the automation roots` — but `/elsewhere/proxy.mov` is not absolute on Windows, where it is refused for that instead and the assertion fails. The gate runs ubuntu only, so it stayed green. A sibling of the write root under the temp directory is absolute on every platform, so the refusal is the one the test is about. Co-Authored-By: Claude Opus 5 --- crates/automation/src/tests.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/crates/automation/src/tests.rs b/crates/automation/src/tests.rs index 088bca335..e2acce85f 100644 --- a/crates/automation/src/tests.rs +++ b/crates/automation/src/tests.rs @@ -1415,8 +1415,11 @@ fn automation_roots_refuse_a_queued_output_from_an_unsaved_project() { // Naming an output inside a write root is how it is done. call_json(&mut s, "execute_command", json!({"command": "renderQueue.add", "params": {"comp": "A", "output": p("named.mp4")}})); // A proxy named outside the roots is refused. Whether that reads as a write or a read is - // #1347's to classify, so this asserts the refusal and not its wording. - let (c, err) = call(&mut s, "execute_command", json!({"command": "file.createProxy", "params": {"comp": "A", "path": "/elsewhere/proxy.mov"}})); + // #1347's to classify, so this asserts the refusal and not its wording. The path is a sibling + // of the write root rather than `/elsewhere/…`, which is not absolute on Windows and would be + // refused for that instead. + let outside = base.join("elsewhere").join("proxy.mov").to_string_lossy().into_owned(); + let (c, err) = call(&mut s, "execute_command", json!({"command": "file.createProxy", "params": {"comp": "A", "path": outside}})); assert!(err, "a proxy outside the roots should be refused: {c:?}"); assert!(c[0]["text"].as_str().unwrap_or_default().contains("outside the automation roots"), "{c:?}"); // Once the project is saved there, the default output (beside it) is queued as before.