fix: use node dist/cli.js instead of npx tsx in thread-step-count tests
CI / check (pull_request) Successful in 3m30s

npx tsx hangs in CI Docker (30s+ timeout). node dist/cli.js runs in <2s.
This commit is contained in:
2026-06-04 11:57:32 +00:00
parent 58b58d511e
commit 66c2e2a79b
@@ -3,11 +3,11 @@ import { dirname, join } from "node:path";
import { fileURLToPath } from "node:url"; import { fileURLToPath } from "node:url";
import { describe, expect, test } from "vitest"; import { describe, expect, test } from "vitest";
const CLI_PATH = join(dirname(fileURLToPath(import.meta.url)), "..", "cli.js"); const CLI_PATH = join(dirname(fileURLToPath(import.meta.url)), "..", "..", "dist", "cli.js");
function runCli(args: string[]): { stdout: string; stderr: string; exitCode: number } { function runCli(args: string[]): { stdout: string; stderr: string; exitCode: number } {
try { try {
const stdout = execFileSync("npx", ["tsx", CLI_PATH, ...args], { const stdout = execFileSync("node", [CLI_PATH, ...args], {
encoding: "utf8", encoding: "utf8",
env: { ...process.env, UWF_HOME: "/tmp/uwf-test-nonexistent" }, env: { ...process.env, UWF_HOME: "/tmp/uwf-test-nonexistent" },
stdio: ["ignore", "pipe", "pipe"], stdio: ["ignore", "pipe", "pipe"],