test: dedupe exec approval mock read · openclaw/openclaw@1eeec9e
steipete
·
2026-05-13
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -210,11 +210,11 @@ function requireFirstCallArg(
|
210 | 210 | mock: ReturnType<typeof vi.fn>, |
211 | 211 | label: string, |
212 | 212 | ): Record<string, unknown> { |
213 | | -const firstCall = mock.mock.calls.at(0); |
| 213 | +const firstCall = mock.mock.calls[0]; |
214 | 214 | if (!firstCall) { |
215 | 215 | throw new Error(`expected ${label} call`); |
216 | 216 | } |
217 | | -return requireRecord(firstCall.at(0), label); |
| 217 | +return requireRecord(firstCall[0], label); |
218 | 218 | } |
219 | 219 | |
220 | 220 | function requireFirstPayload(deliver: ReturnType<typeof vi.fn>): ReplyPayload { |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。