test: spell out thinking option captures · openclaw/openclaw@1b92d8f
shakkernerd
·
2026-05-12
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -53,8 +53,11 @@ describe("OpenAI thinking contract", () => {
|
53 | 53 | |
54 | 54 | await agent.prompt("hello"); |
55 | 55 | |
56 | | -expect(capturedOptions).toHaveLength(1); |
57 | | -expect(capturedOptions[0]?.reasoning).toBe(expectedReasoning); |
| 56 | +expect(capturedOptions).toStrictEqual([ |
| 57 | +expect.objectContaining({ |
| 58 | +reasoning: expectedReasoning, |
| 59 | +}), |
| 60 | +]); |
58 | 61 | }, |
59 | 62 | ); |
60 | 63 | |
@@ -72,8 +75,11 @@ describe("OpenAI thinking contract", () => {
|
72 | 75 | |
73 | 76 | await agent.prompt("hello"); |
74 | 77 | |
75 | | -expect(capturedOptions).toHaveLength(1); |
76 | | -expect(capturedOptions[0]?.reasoning).toBeUndefined(); |
| 78 | +expect(capturedOptions).toStrictEqual([ |
| 79 | +expect.not.objectContaining({ |
| 80 | +reasoning: expect.anything(), |
| 81 | +}), |
| 82 | +]); |
77 | 83 | }, |
78 | 84 | ); |
79 | 85 | |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。