test: tighten matrix backup reset delete assertion · openclaw/openclaw@fb43f3a
shakkernerd
·
2026-05-11
·
via Recent Commits to openclaw:main
File tree
extensions/matrix/src/matrix
| Original file line number | Diff line number | Diff line change |
|---|
@@ -3106,10 +3106,13 @@ describe("MatrixClient crypto bootstrapping", () => {
|
3106 | 3106 | setupNewSecretStorage: true, |
3107 | 3107 | }); |
3108 | 3108 | expect(loadSessionBackupPrivateKeyFromSecretStorage).toHaveBeenCalledTimes(1); |
3109 | | -expect(doRequest).not.toHaveBeenCalledWith( |
3110 | | -"DELETE", |
3111 | | -expect.stringContaining("/room_keys/version/"), |
| 3109 | +const deleteRoomKeyVersionCalls = doRequest.mock.calls.filter( |
| 3110 | +([method, endpoint]) => |
| 3111 | +method === "DELETE" && |
| 3112 | +typeof endpoint === "string" && |
| 3113 | +endpoint.includes("/room_keys/version/"), |
3112 | 3114 | ); |
| 3115 | +expect(deleteRoomKeyVersionCalls).toStrictEqual([]); |
3113 | 3116 | }); |
3114 | 3117 | |
3115 | 3118 | it("forces SSSS recreation when backup-secret access returns a falsey callback error before reset", async () => { |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。