diff --git a/tests/windows/windows-atomic-write-acl-rearm.test.ts b/tests/windows/windows-atomic-write-acl-rearm.test.ts index 4775e99a43b..258a4425c20 100644 --- a/tests/windows/windows-atomic-write-acl-rearm.test.ts +++ b/tests/windows/windows-atomic-write-acl-rearm.test.ts @@ -62,7 +62,9 @@ function runAcl(args: string[]): IcaclsResult { } beforeEach(() => { - root = native.mkdtempSync(join(tmpdir(), "ocx-atomic-acl-rearm-")); + // The writer resolves the destination's real parent, and macOS tmpdir() is a symlink + // (/var -> /private/var); the unlink fixture must match the path the writer actually uses. + root = native.realpathSync(native.mkdtempSync(join(tmpdir(), "ocx-atomic-acl-rearm-"))); native.writeFileSync(join(root, "secret.json"), "previous", "utf8"); previousTimeout = process.env.OPENCODEX_ACL_TIMEOUT_MS; previousVerify = process.env.OPENCODEX_ACL_VERIFY_EXISTING;