test: tighten voice consult session assertion · openclaw/openclaw@e11a2dc
shakkernerd
·
2026-05-09
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -110,7 +110,11 @@ describe("realtime voice agent consult runtime", () => {
|
110 | 110 | }); |
111 | 111 | |
112 | 112 | expect(result).toEqual({ text: "Speak this." }); |
113 | | -expect(sessionStore["voice:15550001234"]?.sessionId).toEqual(expect.stringMatching(/\S/)); |
| 113 | +const voiceSession = sessionStore["voice:15550001234"]; |
| 114 | +if (!voiceSession) { |
| 115 | +throw new Error("Expected voice consult session entry"); |
| 116 | +} |
| 117 | +expect(voiceSession.sessionId).toEqual(expect.stringMatching(/\S/)); |
114 | 118 | expect(runEmbeddedPiAgent).toHaveBeenCalledWith( |
115 | 119 | expect.objectContaining({ |
116 | 120 | sessionKey: "voice:15550001234", |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。