test(cli): repair startup progress checks · openclaw/openclaw@e19f05b
steipete
·
2026-05-17
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -1400,14 +1400,17 @@ describe("run-node script", () => {
|
1400 | 1400 | it("shows tty progress while rebuilding source-checkout artifacts", async () => { |
1401 | 1401 | await withTempDir({ prefix: "openclaw-run-node-" }, async (tmp) => { |
1402 | 1402 | await setupTrackedProject(tmp, { |
| 1403 | +files: { |
| 1404 | +[ROOT_SRC]: "export const value = 1;\n", |
| 1405 | +}, |
1403 | 1406 | oldPaths: [ROOT_SRC, ROOT_TSCONFIG, ROOT_PACKAGE], |
1404 | 1407 | buildPaths: [DIST_ENTRY, BUILD_STAMP], |
1405 | 1408 | }); |
1406 | 1409 | const { spawn, spawnSync } = createSpawnRecorder(); |
1407 | 1410 | const stderrChunks: string[] = []; |
1408 | 1411 | const stderr = { |
1409 | 1412 | isTTY: true, |
1410 | | -write: vi.fn((chunk: string) => { |
| 1413 | +write: vi.fn((chunk: string | Buffer) => { |
1411 | 1414 | stderrChunks.push(String(chunk)); |
1412 | 1415 | return true; |
1413 | 1416 | }), |
@@ -1430,7 +1433,7 @@ describe("run-node script", () => {
|
1430 | 1433 | runRuntimePostBuild: async () => {}, |
1431 | 1434 | execPath: process.execPath, |
1432 | 1435 | platform: process.platform, |
1433 | | -}); |
| 1436 | +} as Parameters<typeof runNodeMain>[0] & { stdout: NodeJS.WriteStream }); |
1434 | 1437 | |
1435 | 1438 | expect(exitCode).toBe(0); |
1436 | 1439 | const stderrText = stderrChunks.join(""); |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。