Skip to content

Commit d111655

Browse files
committed
fix(test): handle nullable execFile error codes in auth e2e
1 parent 47ff83f commit d111655

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎packages/commands/tests/e2e/auth.e2e.test.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { createServer, type Server } from "http";
33
import { tmpdir } from "os";
44
import { join } from "path";
55
import { Readable } from "node:stream";
6-
import { execFile } from "node:child_process";
6+
import { execFile, type ExecFileException } from "node:child_process";
77
import { fileURLToPath } from "node:url";
88
import { afterAll, beforeAll, describe, expect, test, vi } from "vite-plus/test";
99
import { readConfigFile, readConfigProfiles, writeConfigFile } from "bailian-cli-core";
@@ -301,7 +301,7 @@ describe("e2e: auth", () => {
301301
},
302302
});
303303
try {
304-
const result = await new Promise<{ code: number | string | undefined; output: string }>(
304+
const result = await new Promise<{ code: ExecFileException["code"]; output: string }>(
305305
(resolve) => {
306306
const child = execFile(
307307
process.execPath,

0 commit comments

Comments
 (0)