test: dedupe acp lifecycle mock reads · openclaw/openclaw@92c84bb
steipete
·
2026-05-13
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -99,7 +99,7 @@ function mockReadySession(params: {
|
99 | 99 | |
100 | 100 | function expectCloseArgs(): Record<string, unknown> { |
101 | 101 | expect(managerMocks.closeSession).toHaveBeenCalledTimes(1); |
102 | | -const call = managerMocks.closeSession.mock.calls.at(0); |
| 102 | +const call = managerMocks.closeSession.mock.calls[0]; |
103 | 103 | if (!call) { |
104 | 104 | throw new Error("expected closeSession call"); |
105 | 105 | } |
@@ -108,7 +108,7 @@ function expectCloseArgs(): Record<string, unknown> {
|
108 | 108 | |
109 | 109 | function expectInitializeArgs(): Record<string, unknown> { |
110 | 110 | expect(managerMocks.initializeSession).toHaveBeenCalledTimes(1); |
111 | | -const call = managerMocks.initializeSession.mock.calls.at(0); |
| 111 | +const call = managerMocks.initializeSession.mock.calls[0]; |
112 | 112 | if (!call) { |
113 | 113 | throw new Error("expected initializeSession call"); |
114 | 114 | } |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。