test: assert compaction split merge calls · openclaw/openclaw@8a58fa0
shakkernerd
·
2026-05-12
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -94,7 +94,7 @@ describe("compaction identifier-preservation instructions", () => {
|
94 | 94 | minMessagesForSplit: 4, |
95 | 95 | }); |
96 | 96 | |
97 | | -expect(mockGenerateSummary.mock.calls.length).toBeGreaterThan(1); |
| 97 | +expect(mockGenerateSummary).toHaveBeenCalledTimes(3); |
98 | 98 | for (const call of mockGenerateSummary.mock.calls) { |
99 | 99 | expect(extractSummaryInstructions(call)).toContain( |
100 | 100 | "Preserve all opaque identifiers exactly as written", |
@@ -110,6 +110,7 @@ describe("compaction identifier-preservation instructions", () => {
|
110 | 110 | customInstructions: "Prioritize customer-visible regressions.", |
111 | 111 | }); |
112 | 112 | |
| 113 | +expect(mockGenerateSummary).toHaveBeenCalledTimes(3); |
113 | 114 | const mergedCall = mockGenerateSummary.mock.calls.at(-1); |
114 | 115 | const instructions = extractSummaryInstructions(mergedCall); |
115 | 116 | expect(instructions).toContain("Merge these partial summaries into a single cohesive summary."); |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。