Skip to content

Commit 97f6c2c

Browse files
test(dbt-tools): compare the bridge path against the install dir's real path
Node loads the published bundle by its real path. On macOS `tmpdir()` is under the `/var` symlink, so the published-package test expected `/var/...` while the bridge ran from `/private/var/...`. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_0172qrhMa5TQgETASi5hxMqD
1 parent ccc92cc commit 97f6c2c

1 file changed

Lines changed: 13 additions & 2 deletions

File tree

‎packages/dbt-tools/test/build-integrity.test.ts‎

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,15 @@
11
import { describe, test, expect, beforeAll } from "bun:test"
2-
import { chmodSync, cpSync, existsSync, mkdirSync, mkdtempSync, readFileSync, rmSync, writeFileSync } from "fs"
2+
import {
3+
chmodSync,
4+
cpSync,
5+
existsSync,
6+
mkdirSync,
7+
mkdtempSync,
8+
readFileSync,
9+
realpathSync,
10+
rmSync,
11+
writeFileSync,
12+
} from "fs"
313
import { tmpdir } from "os"
414
import { dirname, join } from "path"
515
import { $ } from "bun"
@@ -102,7 +112,8 @@ describe("build integrity", () => {
102112
.quiet()
103113
.nothrow()
104114

105-
const script = join(installed, "dist", "node_python_bridge.py")
115+
// Node loads the bundle by its real path; on macOS `tmpdir()` is under the `/var` symlink.
116+
const script = join(realpathSync(installed), "dist", "node_python_bridge.py")
106117
const runs = readFileSync(argvLog, "utf8").split("\n")
107118
expect(runs).toContain(script)
108119
expect(existsSync(script)).toBe(true)

0 commit comments

Comments
 (0)