Files
nanobot/webui/src/tests/channel-catalog.test.ts
T

29 lines
778 B
TypeScript
Raw Normal View History

2026-07-13 13:11:46 +08:00
import { describe, expect, it } from "vitest";
import { SLACK_SOCKET_MODE_MANIFEST } from "@/components/settings/channels/catalog";
describe("Slack setup manifest", () => {
it.each(["app_mention", "message.channels", "message.groups", "message.im", "message.mpim"])(
"subscribes to %s",
(event) => expect(SLACK_SOCKET_MODE_MANIFEST).toContain(` - ${event}`),
);
it.each([
"app_mentions:read",
"channels:history",
"channels:read",
"chat:write",
"files:read",
"files:write",
"groups:history",
"groups:read",
"im:history",
"im:write",
"mpim:history",
"reactions:write",
"users:read",
])("requests the %s scope", (scope) => {
expect(SLACK_SOCKET_MODE_MANIFEST).toContain(` - ${scope}`);
});
});