Skip to content
TypeScript

test(server): resolve the temp dir before matching the symlinked entrypoint (#9400)

Doksanbira3d150514152
diff --git a/apps/server/src/entrypoint.test.ts b/apps/server/src/entrypoint.test.ts
index bf8247fd429..509008f96af 100644
--- a/apps/server/src/entrypoint.test.ts
+++ b/apps/server/src/entrypoint.test.ts
@@ -54,9 +54,11 @@ describe("isEntrypoint", () => {
NodeFS.writeFileSync(real, "");
NodeFS.symlinkSync(real, link);
+ // Node resolves the module URL to the real path, and on macOS the temp
+ // directory itself sits behind a symlink (`/var` -> `/private/var`).
expect(
isEntrypoint({
- moduleUrl: NodeURL.pathToFileURL(real).href,
+ moduleUrl: NodeURL.pathToFileURL(NodeFS.realpathSync(real)).href,
entryPath: link,
runtimeMain: undefined,
}),