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

推荐订阅源

T
Tailwind CSS Blog
人人都是产品经理
人人都是产品经理
博客园 - 叶小钗
大猫的无限游戏
大猫的无限游戏
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 【当耐特】
The Cloudflare Blog
博客园 - 聂微东
博客园 - 司徒正美
量子位
博客园 - 三生石上(FineUI控件)
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
G
Google Developers Blog
Apple Machine Learning Research
Apple Machine Learning Research
罗磊的独立博客
酷 壳 – CoolShell
酷 壳 – CoolShell
Y
Y Combinator Blog
S
SegmentFault 最新的问题
T
The Blog of Author Tim Ferriss
P
Proofpoint News Feed
Google DeepMind News
Google DeepMind News
Blog — PlanetScale
Blog — PlanetScale
有赞技术团队
有赞技术团队
A
About on SuperTechFans

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: guard embedded three-hit mock calls · openclaw/open...
steipete · 2026-05-12 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -320,8 +320,9 @@ describe("runEmbeddedPiAgent", () => {

320320

enqueue: immediateEnqueue,

321321

});

322322
323-

const resolveModelCall = (resolveModelAsyncMock as unknown as { mock: { calls: unknown[][] } })

324-

.mock.calls[0];

323+

const resolveModelCall = (

324+

resolveModelAsyncMock as unknown as { mock: { calls: unknown[][] } }

325+

).mock.calls.at(0);

325326

expect(resolveModelCall?.[0]).toBe("openrouter");

326327

expect(resolveModelCall?.[1]).toBe("openrouter/auto");

327328

expect(resolveModelCall?.[2]).toBe(agentDir);

@@ -369,7 +370,7 @@ describe("runEmbeddedPiAgent", () => {

369370

sessionId: "resume-123",

370371

agentId: undefined,

371372

});

372-

const firstCall = runEmbeddedAttemptMock.mock.calls[0]?.[0] as { sessionKey?: string };

373+

const firstCall = runEmbeddedAttemptMock.mock.calls.at(0)?.[0] as { sessionKey?: string };

373374

expect(firstCall.sessionKey).toBe("agent:test:resolved");

374375

});

375376

@@ -410,7 +411,7 @@ describe("runEmbeddedPiAgent", () => {

410411

sessionId: "resume-124",

411412

agentId: undefined,

412413

});

413-

const firstCall = runEmbeddedAttemptMock.mock.calls[0]?.[0] as { sessionKey?: string };

414+

const firstCall = runEmbeddedAttemptMock.mock.calls.at(0)?.[0] as { sessionKey?: string };

414415

expect(firstCall.sessionKey).toBeUndefined();

415416

});

416417
Original file line numberDiff line numberDiff line change

@@ -75,7 +75,7 @@ describe("createFailoverDecisionLogger", () => {

7575
7676

logDecision("fallback_model");

7777
78-

const [message, details] = warnSpy.mock.calls[0] ?? [];

78+

const [message, details] = warnSpy.mock.calls.at(0) ?? [];

7979

expect(message).toBe("embedded run failover decision");

8080

const observation = details as

8181

| {

@@ -115,10 +115,10 @@ describe("createFailoverDecisionLogger", () => {

115115

logDecision("surface_error");

116116
117117

expect(

118-

(warnSpy.mock.calls[0]?.[1] as { consoleMessage?: string } | undefined)?.consoleMessage,

118+

(warnSpy.mock.calls.at(0)?.[1] as { consoleMessage?: string } | undefined)?.consoleMessage,

119119

).toContain("from=openai/gpt-5.4");

120120

expect(

121-

(warnSpy.mock.calls[0]?.[1] as { consoleMessage?: string } | undefined)?.consoleMessage,

121+

(warnSpy.mock.calls.at(0)?.[1] as { consoleMessage?: string } | undefined)?.consoleMessage,

122122

).not.toContain("to=openai/gpt-5.4");

123123

});

124124

});

Original file line numberDiff line numberDiff line change

@@ -83,7 +83,7 @@ describe("runEmbeddedPiAgent usage reporting", () => {

8383

workspaceDir: "/tmp/workspace",

8484

allowGatewaySubagentBinding: true,

8585

});

86-

const attemptInput = mockedRunEmbeddedAttempt.mock.calls[0]?.[0] as

86+

const attemptInput = mockedRunEmbeddedAttempt.mock.calls.at(0)?.[0] as

8787

| { allowGatewaySubagentBinding?: boolean }

8888

| undefined;

8989

expect(attemptInput?.allowGatewaySubagentBinding).toBe(true);

@@ -110,7 +110,7 @@ describe("runEmbeddedPiAgent usage reporting", () => {

110110

senderE164: "+15551234567",

111111

});

112112
113-

const attemptInput = mockedRunEmbeddedAttempt.mock.calls[0]?.[0] as

113+

const attemptInput = mockedRunEmbeddedAttempt.mock.calls.at(0)?.[0] as

114114

| {

115115

senderId?: string;

116116

senderName?: string;

@@ -143,7 +143,7 @@ describe("runEmbeddedPiAgent usage reporting", () => {

143143

memoryFlushWritePath: "memory/2026-03-10.md",

144144

});

145145
146-

const attemptInput = mockedRunEmbeddedAttempt.mock.calls[0]?.[0] as

146+

const attemptInput = mockedRunEmbeddedAttempt.mock.calls.at(0)?.[0] as

147147

| { trigger?: string; memoryFlushWritePath?: string }

148148

| undefined;

149149

expect(attemptInput?.trigger).toBe("memory");

Original file line numberDiff line numberDiff line change

@@ -584,7 +584,7 @@ describe("handleMessageUpdate commentary phase", () => {

584584

);

585585
586586

expect(onAgentEvent).toHaveBeenCalledTimes(1);

587-

const event = onAgentEvent.mock.calls[0]?.[0] as

587+

const event = onAgentEvent.mock.calls.at(0)?.[0] as

588588

| { stream?: string; data?: { text?: string; delta?: string } }

589589

| undefined;

590590

expect(event?.stream).toBe("assistant");

@@ -629,7 +629,7 @@ describe("handleMessageEnd", () => {

629629

},

630630

} as never);

631631
632-

const warnCall = warn.mock.calls[0];

632+

const warnCall = warn.mock.calls.at(0);

633633

expect(warnCall?.[0]).toBe(

634634

"Assistant reply looks like a tool call, but no structured tool invocation was emitted; treating it as text.",

635635

);

@@ -839,7 +839,7 @@ describe("handleMessageEnd", () => {

839839

} as never);

840840
841841

expect(onAgentEvent).toHaveBeenCalledTimes(1);

842-

const event = onAgentEvent.mock.calls[0]?.[0] as

842+

const event = onAgentEvent.mock.calls.at(0)?.[0] as

843843

| { stream?: string; data?: { text?: string; delta?: string; replace?: boolean } }

844844

| undefined;

845845

expect(event?.stream).toBe("assistant");

Original file line numberDiff line numberDiff line change

@@ -41,7 +41,7 @@ describe("subscribeEmbeddedPiSession reply tags", () => {

4141

emit({ type: "message_end", message: assistantMessage });

4242
4343

expect(onBlockReply).toHaveBeenCalledTimes(1);

44-

const payload = onBlockReply.mock.calls[0]?.[0];

44+

const payload = onBlockReply.mock.calls.at(0)?.[0];

4545

expect(payload?.text).toBe("Hello");

4646

expect(payload?.replyToCurrent).toBe(true);

4747

expect(payload?.replyToTag).toBe(true);

@@ -61,8 +61,8 @@ describe("subscribeEmbeddedPiSession reply tags", () => {

6161

emit({ type: "message_end", message: assistantMessage });

6262
6363

expect(onBlockReply).toHaveBeenCalledTimes(2);

64-

expect(onBlockReply.mock.calls[0]?.[0]?.text).toBe("Hello");

65-

expect(onBlockReply.mock.calls[1]?.[0]?.text).toBe("[[");

64+

expect(onBlockReply.mock.calls.at(0)?.[0]?.text).toBe("Hello");

65+

expect(onBlockReply.mock.calls.at(1)?.[0]?.text).toBe("[[");

6666

});

6767
6868

it("streams partial replies past reply_to tags split across chunks", () => {