惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

GbyAI
GbyAI
The GitHub Blog
The GitHub Blog
小众软件
小众软件
美团技术团队
博客园 - 司徒正美
G
Google Developers Blog
Blog — PlanetScale
Blog — PlanetScale
Hugging Face - Blog
Hugging Face - Blog
博客园_首页
大猫的无限游戏
大猫的无限游戏
罗磊的独立博客
Recent Announcements
Recent Announcements
酷 壳 – CoolShell
酷 壳 – CoolShell
D
Docker
J
Java Code Geeks
Last Week in AI
Last Week in AI
V
Visual Studio Blog
Microsoft Azure Blog
Microsoft Azure Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
P
Proofpoint News Feed
V
V2EX
C
Check Point Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
MyScale Blog
MyScale Blog

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
test: tighten run node assertions · openclaw/openclaw@573...
steipete · 2026-05-11 · via Recent Commits to openclaw:main

@@ -171,7 +171,13 @@ function resolvePath(tmp: string, relativePath: string) {

171171

}

172172173173

async function expectPathMissing(targetPath: string): Promise<void> {

174-

await expect(fs.access(targetPath)).rejects.toMatchObject({ code: "ENOENT" });

174+

let accessError: unknown;

175+

try {

176+

await fs.access(targetPath);

177+

} catch (error) {

178+

accessError = error;

179+

}

180+

expect((accessError as NodeJS.ErrnoException | undefined)?.code).toBe("ENOENT");

175181

}

176182177183

async function writeProjectFiles(tmp: string, files: Record<string, string>) {

@@ -346,9 +352,10 @@ async function runQaCommand(params: {

346352

}

347353348354

async function expectManifestId(tmp: string, relativePath: string, id: string) {

349-

await expect(

350-

fs.readFile(resolvePath(tmp, relativePath), "utf-8").then((raw) => JSON.parse(raw)),

351-

).resolves.toMatchObject({ id });

355+

const manifest = JSON.parse(await fs.readFile(resolvePath(tmp, relativePath), "utf-8")) as {

356+

id?: unknown;

357+

};

358+

expect(manifest.id).toBe(id);

352359

}

353360354361

describe("run-node script", () => {

@@ -444,11 +451,7 @@ describe("run-node script", () => {

444451

await expect(

445452

fs.readFile(resolvePath(tmp, "dist/plugin-sdk/root-alias.cjs"), "utf-8"),

446453

).resolves.toContain("module.exports = {};");

447-

await expect(

448-

fs

449-

.readFile(resolvePath(tmp, DIST_EXTENSION_MANIFEST), "utf-8")

450-

.then((raw) => JSON.parse(raw)),

451-

).resolves.toMatchObject({ id: "demo" });

454+

await expectManifestId(tmp, DIST_EXTENSION_MANIFEST, "demo");

452455

await expect(

453456

fs.readFile(resolvePath(tmp, DIST_EXTENSION_PACKAGE), "utf-8"),

454457

).resolves.toContain(

@@ -843,15 +846,13 @@ describe("run-node script", () => {

843846

const exitCode = await runQaCommand({ tmp, spawn, spawnSync, runRuntimePostBuild });

844847845848

expect(exitCode).toBe(0);

846-

expect(runRuntimePostBuild).toHaveBeenCalledWith(

847-

expect.objectContaining({

848-

cwd: tmp,

849-

env: expect.objectContaining({

850-

OPENCLAW_BUILD_PRIVATE_QA: "1",

851-

OPENCLAW_ENABLE_PRIVATE_QA_CLI: "1",

852-

}),

853-

}),

854-

);

849+

expect(runRuntimePostBuild).toHaveBeenCalledTimes(1);

850+

const postBuildParams = runRuntimePostBuild.mock.calls[0]?.[0] as

851+

| { cwd?: string; env?: Record<string, string | undefined> }

852+

| undefined;

853+

expect(postBuildParams?.cwd).toBe(tmp);

854+

expect(postBuildParams?.env?.OPENCLAW_BUILD_PRIVATE_QA).toBe("1");

855+

expect(postBuildParams?.env?.OPENCLAW_ENABLE_PRIVATE_QA_CLI).toBe("1");

855856

});

856857

});

857858

@@ -1326,11 +1327,11 @@ describe("run-node script", () => {

13261327

const exitCode = await exitCodePromise;

1327132813281329

expect(exitCode).toBe(143);

1329-

expect(spawn).toHaveBeenCalledWith(

1330-

process.execPath,

1331-

["openclaw.mjs", "status"],

1332-

expect.objectContaining({ stdio: "inherit" }),

1333-

);

1330+

expect(spawn).toHaveBeenCalledTimes(1);

1331+

const spawnCall = spawn.mock.calls[0] as [string, string[], { stdio?: unknown }] | undefined;

1332+

expect(spawnCall?.[0]).toBe(process.execPath);

1333+

expect(spawnCall?.[1]).toEqual(["openclaw.mjs", "status"]);

1334+

expect(spawnCall?.[2].stdio).toBe("inherit");

13341335

expect(child.kill).toHaveBeenCalledWith("SIGTERM");

13351336

expect(fakeProcess.listenerCount("SIGINT")).toBe(0);

13361337

expect(fakeProcess.listenerCount("SIGTERM")).toBe(0);