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

推荐订阅源

钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
J
Java Code Geeks
B
Blog
腾讯CDC
博客园 - 三生石上(FineUI控件)
S
SegmentFault 最新的问题
H
Hackread – Cybersecurity News, Data Breaches, AI and More
博客园 - Franky
罗磊的独立博客
月光博客
月光博客
Jina AI
Jina AI
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
D
Docker
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
G
Google Developers Blog
V
Visual Studio Blog
I
InfoQ
有赞技术团队
有赞技术团队
D
DataBreaches.Net
Microsoft Security Blog
Microsoft Security Blog
WordPress大学
WordPress大学
阮一峰的网络日志
阮一峰的网络日志
宝玉的分享
宝玉的分享
Blog — PlanetScale
Blog — PlanetScale

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 config schema assertions · openclaw/opencla...
steipete · 2026-05-10 · via Recent Commits to openclaw:main

@@ -213,11 +213,9 @@ describe("config schema", () => {

213213

const serialized = JSON.stringify(res);

214214

expect(serialized).not.toContain("oversized-marker");

215215

const lookup = lookupConfigSchema(res, "plugins.entries.huge.config");

216-

expect(lookup?.schema).toMatchObject({

217-

type: "object",

218-

additionalProperties: true,

219-

description: expect.stringContaining("omitted"),

220-

});

216+

expect(lookup?.schema?.type).toBe("object");

217+

expect(lookup?.schema?.additionalProperties).toBe(true);

218+

expect(lookup?.schema?.description).toContain("omitted");

221219

});

222220223221

it("omits later plugin schemas after the aggregate extension schema budget is exhausted", () => {

@@ -239,12 +237,10 @@ describe("config schema", () => {

239237240238

const first = lookupConfigSchema(res, "plugins.entries.plugin-0.config.value");

241239

const last = lookupConfigSchema(res, "plugins.entries.plugin-39.config");

242-

expect(first?.schema).toMatchObject({ type: "string" });

243-

expect(last?.schema).toMatchObject({

244-

type: "object",

245-

additionalProperties: true,

246-

description: expect.stringContaining("omitted"),

247-

});

240+

expect(first?.schema?.type).toBe("string");

241+

expect(last?.schema?.type).toBe("object");

242+

expect(last?.schema?.additionalProperties).toBe(true);

243+

expect(last?.schema?.description).toContain("omitted");

248244

});

249245250246

it("looks up plugin config paths for slash-delimited plugin ids", () => {

@@ -266,11 +262,10 @@ describe("config schema", () => {

266262

const lookup = lookupConfigSchema(res, "plugins.entries.pack/one.config");

267263

expect(lookup?.path).toBe("plugins.entries.pack/one.config");

268264

expect(lookup?.hintPath).toBe("plugins.entries.pack/one.config");

269-

expect(lookup?.children.find((child) => child.key === "provider")).toMatchObject({

270-

key: "provider",

271-

path: "plugins.entries.pack/one.config.provider",

272-

type: "string",

273-

});

265+

const providerChild = lookup?.children.find((child) => child.key === "provider");

266+

expect(providerChild?.key).toBe("provider");

267+

expect(providerChild?.path).toBe("plugins.entries.pack/one.config.provider");

268+

expect(providerChild?.type).toBe("string");

274269

});

275270276271

it("adds heartbeat target hints with dynamic channels", () => {

@@ -322,15 +317,13 @@ describe("config schema", () => {

322317

});

323318324319

expect(parsed?.web?.fetch?.readability).toBe(true);

325-

expect(parsed?.web?.fetch).toMatchObject({

326-

firecrawl: {

327-

enabled: true,

328-

apiKey: "firecrawl-test-key",

329-

baseUrl: "https://api.firecrawl.dev",

330-

onlyMainContent: true,

331-

maxAgeMs: 60_000,

332-

timeoutSeconds: 15,

333-

},

320+

expect(parsed?.web?.fetch?.firecrawl).toEqual({

321+

enabled: true,

322+

apiKey: "firecrawl-test-key",

323+

baseUrl: "https://api.firecrawl.dev",

324+

onlyMainContent: true,

325+

maxAgeMs: 60_000,

326+

timeoutSeconds: 15,

334327

});

335328

});

336329

@@ -424,14 +417,15 @@ describe("config schema", () => {

424417

},

425418

});

426419427-

expect(result).toMatchObject({ success: false });

420+

expect(result.success).toBe(false);

428421

if (!result.success) {

429-

expect(result.error.issues).toContainEqual(

430-

expect.objectContaining({

431-

keys: ["allowPrivateNetwork"],

432-

path: ["media", "image", "models", 0, "request"],

433-

}),

422+

const requestIssue = result.error.issues.find(

423+

(issue) =>

424+

JSON.stringify(issue.path) === JSON.stringify(["media", "image", "models", 0, "request"]),

434425

);

426+

expect(requestIssue?.path).toEqual(["media", "image", "models", 0, "request"]);

427+

const requestKeys = (requestIssue as { keys?: unknown } | undefined)?.keys;

428+

expect(requestKeys).toEqual(["allowPrivateNetwork"]);

435429

}

436430

});

437431

@@ -447,14 +441,14 @@ describe("config schema", () => {

447441

},

448442

});

449443450-

expect(result).toMatchObject({ success: false });

444+

expect(result.success).toBe(false);

451445

if (!result.success) {

452-

expect(result.error.issues).toContainEqual(

453-

expect.objectContaining({

454-

keys: ["nope"],

455-

path: ["web", "fetch", "firecrawl"],

456-

}),

446+

const firecrawlIssue = result.error.issues.find(

447+

(issue) => JSON.stringify(issue.path) === JSON.stringify(["web", "fetch", "firecrawl"]),

457448

);

449+

expect(firecrawlIssue?.path).toEqual(["web", "fetch", "firecrawl"]);

450+

const firecrawlKeys = (firecrawlIssue as { keys?: unknown } | undefined)?.keys;

451+

expect(firecrawlKeys).toEqual(["nope"]);

458452

}

459453

});

460454

@@ -518,10 +512,8 @@ describe("config schema", () => {

518512

expect(lookup?.path).toBe("agents.list.0.identity.avatar");

519513

expect(lookup?.hintPath).toBe("agents.list.*.identity.avatar");

520514

expect(lookup?.hint?.help).toContain("workspace-relative path");

521-

expect(lookup?.schema).toMatchObject({

522-

title: "Identity Avatar",

523-

description: expect.stringContaining("Agent avatar"),

524-

});

515+

expect(lookup?.schema?.title).toBe("Identity Avatar");

516+

expect(lookup?.schema?.description).toContain("Agent avatar");

525517

});

526518527519

it("normalizes bracketed lookup paths", () => {

@@ -555,7 +547,7 @@ describe("config schema", () => {

555547556548

const lookup = lookupConfigSchema(tupleSchema, "pair.1");

557549

expect(lookup?.path).toBe("pair.1");

558-

expect(lookup?.schema).toMatchObject({ type: "number" });

550+

expect(lookup?.schema?.type).toBe("number");

559551

expect((lookup?.schema as { items?: unknown } | undefined)?.items).toBeUndefined();

560552

});

561553