test(extensions): dedupe bundled entry smoke tests

This commit is contained in:
Vincent Koc
2026-04-12 03:08:25 +01:00
parent 9d126dc645
commit 45147d5ce3
7 changed files with 83 additions and 59 deletions

View File

@@ -1,4 +1,5 @@
import { beforeEach, describe, expect, it, vi } from "vitest";
import { beforeEach, describe, vi } from "vitest";
import { assertBundledChannelEntries } from "../../test/helpers/bundled-channel-entry.ts";
import entry from "./index.js";
import setupEntry from "./setup-entry.js";
@@ -7,13 +8,11 @@ describe("telegram bundled entries", () => {
vi.useRealTimers();
});
it("declares the channel entry without importing the broad api barrel", () => {
expect(entry.id).toBe("telegram");
expect(entry.name).toBe("Telegram");
});
it("declares the setup plugin without importing the broad api barrel", () => {
expect(setupEntry.kind).toBe("bundled-channel-setup-entry");
expect(typeof setupEntry.loadSetupPlugin).toBe("function");
assertBundledChannelEntries({
entry,
expectedId: "telegram",
expectedName: "Telegram",
setupEntry,
channelMessage: "declares the channel entry without importing the broad api barrel",
});
});