test: dedupe openai image mock reads · openclaw/openclaw@a282bdc
steipete
·
2026-05-13
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -1163,7 +1163,7 @@ describe("openai image generation provider", () => {
|
1163 | 1163 | ], |
1164 | 1164 | }); |
1165 | 1165 | |
1166 | | -const body = postJsonRequestMock.mock.calls.at(0)?.[0].body as { |
| 1166 | +const body = postJsonRequestMock.mock.calls[0]?.[0].body as { |
1167 | 1167 | input: Array<{ content: Array<Record<string, string>> }>; |
1168 | 1168 | }; |
1169 | 1169 | expect(body.input[0]?.content).toEqual([ |
@@ -1192,7 +1192,7 @@ describe("openai image generation provider", () => {
|
1192 | 1192 | }); |
1193 | 1193 | |
1194 | 1194 | expect(postJsonRequestMock).toHaveBeenCalledTimes(2); |
1195 | | -const firstBody = postJsonRequestMock.mock.calls.at(0)?.[0].body as { |
| 1195 | +const firstBody = postJsonRequestMock.mock.calls[0]?.[0].body as { |
1196 | 1196 | tools: Array<Record<string, unknown>>; |
1197 | 1197 | }; |
1198 | 1198 | expect(firstBody.tools[0]).toEqual({ |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。