Files
openclaw/extensions/whatsapp/index.test.ts
Peter Lee 5c8761976c fix(whatsapp): restart listener on selfChatMode config change (#93873)
Merged via squash.

Prepared head SHA: d85f604f01
Co-authored-by: xialonglee <22994703+xialonglee@users.noreply.github.com>
Co-authored-by: steipete <58493+steipete@users.noreply.github.com>
Reviewed-by: @steipete
2026-06-19 13:41:26 +01:00

23 lines
760 B
TypeScript

// Whatsapp tests cover index plugin behavior.
import { assertBundledChannelEntries } from "openclaw/plugin-sdk/channel-test-helpers";
import { describe, expect, it } from "vitest";
import { whatsappPlugin } from "./channel-plugin-api.js";
import entry from "./index.js";
import setupEntry from "./setup-entry.js";
describe("whatsapp bundled entries", () => {
assertBundledChannelEntries({
entry,
expectedId: "whatsapp",
expectedName: "WhatsApp",
setupEntry,
});
it("declares account config as channel-restart reload metadata", () => {
expect(whatsappPlugin.reload).toEqual({
configPrefixes: ["web", "channels.whatsapp.accounts", "channels.whatsapp.selfChatMode"],
noopPrefixes: ["channels.whatsapp"],
});
});
});