Files
openclaw/extensions/feishu/setup-entry.test.ts
Peter Steinberger 1ef85c7d4c test: make suites safe without isolation (#78834)
* test: make suites safe without isolation

* fix: narrow auth profile credential types

* test: inject channel module loader factory locally
2026-05-07 08:43:29 +01:00

20 lines
608 B
TypeScript

import { afterAll, describe, expect, it, vi } from "vitest";
vi.mock("@larksuiteoapi/node-sdk", () => {
throw new Error("setup entry must not load the Feishu SDK");
});
describe("feishu setup entry", () => {
afterAll(() => {
vi.doUnmock("@larksuiteoapi/node-sdk");
vi.resetModules();
});
it("declares the setup entry without importing Feishu runtime dependencies", async () => {
const { default: setupEntry } = await import("./setup-entry.js");
expect(setupEntry.kind).toBe("bundled-channel-setup-entry");
expect(typeof setupEntry.loadSetupPlugin).toBe("function");
});
});