mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-15 18:20:44 +00:00
test: tighten discord owner allowlist assertion
This commit is contained in:
@@ -269,7 +269,11 @@ describe("discord allowlist helpers", () => {
|
||||
allowFrom: ["*", "user:123"],
|
||||
sender: { id: "123" },
|
||||
});
|
||||
expect(explicitOwner.ownerAllowList).not.toBeNull();
|
||||
if (explicitOwner.ownerAllowList === null) {
|
||||
throw new Error("Expected explicit owner allowlist");
|
||||
}
|
||||
expect(explicitOwner.ownerAllowList.allowAll).toBe(false);
|
||||
expect(explicitOwner.ownerAllowList.ids).toEqual(new Set(["123"]));
|
||||
expect(explicitOwner.ownerAllowed).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user