test: tighten discord route assertions · openclaw/openclaw@48d320b
shakkernerd
·
2026-05-11
·
via Recent Commits to openclaw:main
File tree
extensions/discord/src/monitor
| Original file line number | Diff line number | Diff line change |
|---|
@@ -110,9 +110,13 @@ describe("discord route resolution helpers", () => {
|
110 | 110 | memberRoleIds: [], |
111 | 111 | peer: { kind: "channel", id: "c1" }, |
112 | 112 | }), |
113 | | -).toMatchObject({ |
| 113 | +).toEqual({ |
114 | 114 | agentId: "worker", |
| 115 | +channel: "discord", |
| 116 | +accountId: "default", |
115 | 117 | sessionKey: "agent:worker:discord:channel:c1", |
| 118 | +mainSessionKey: "agent:worker:main", |
| 119 | +lastRoutePolicy: "session", |
116 | 120 | matchedBy: "binding.peer", |
117 | 121 | }); |
118 | 122 | }); |
@@ -131,9 +135,13 @@ describe("discord route resolution helpers", () => {
|
131 | 135 | boundSessionKey: "agent:worker:discord:direct:user-1", |
132 | 136 | matchedBy: "binding.channel", |
133 | 137 | }), |
134 | | -).toMatchObject({ |
| 138 | +).toEqual({ |
135 | 139 | agentId: "worker", |
| 140 | +channel: "discord", |
| 141 | +accountId: "default", |
136 | 142 | sessionKey: "agent:worker:discord:direct:user-1", |
| 143 | +mainSessionKey: "agent:worker:main", |
| 144 | +lastRoutePolicy: "session", |
137 | 145 | matchedBy: "binding.channel", |
138 | 146 | }); |
139 | 147 | }); |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。