test: excise tool result details exactly · openclaw/openclaw@4071fc6
shakkernerd
·
2026-05-13
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -77,13 +77,31 @@ describe("compaction toolResult details stripping", () => {
|
77 | 77 | const chunk = ( |
78 | 78 | piCodingAgentMocks.generateSummary.mock.calls as unknown as Array<[AgentMessage[]]> |
79 | 79 | )[0]?.[0]; |
80 | | -expect(chunk).toMatchObject([ |
| 80 | +expect(chunk).toStrictEqual([ |
81 | 81 | { |
82 | 82 | role: "assistant", |
83 | 83 | content: [ |
84 | 84 | { type: "toolCall", id: "call_1", name: "browser", arguments: { action: "tabs" } }, |
85 | 85 | ], |
| 86 | +api: "openai-responses", |
| 87 | +model: "gpt-5.4", |
| 88 | +provider: "openai", |
| 89 | +stopReason: "toolUse", |
86 | 90 | timestamp: 1, |
| 91 | +usage: { |
| 92 | +cacheRead: 0, |
| 93 | +cacheWrite: 0, |
| 94 | +cost: { |
| 95 | +cacheRead: 0, |
| 96 | +cacheWrite: 0, |
| 97 | +input: 0, |
| 98 | +output: 0, |
| 99 | +total: 0, |
| 100 | +}, |
| 101 | +input: 0, |
| 102 | +output: 0, |
| 103 | +totalTokens: 0, |
| 104 | +}, |
87 | 105 | }, |
88 | 106 | { |
89 | 107 | role: "toolResult", |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。