feat(FN-4057): add printing press built-in plugin entry
Bundled the Printing Press plugin into the dashboard by adding it as a built-in entry in `PluginManager.tsx` with corresponding tests and documentation updates, and included a changeset to publish the change under `@runfusion/fusion`. Fusion-Task-Id: FN-4057
This commit is contained in:
5
.changeset/fn-4057-printing-press-bundled.md
Normal file
5
.changeset/fn-4057-printing-press-bundled.md
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
"@runfusion/fusion": patch
|
||||||
|
---
|
||||||
|
|
||||||
|
Add CLI Printing Press to the built-in plugin catalog in Settings so users can discover and install the bundled plugin directly from Plugin Manager.
|
||||||
@@ -58,7 +58,7 @@ For full multi-project details, see [Plugin Scope in Multi-Project Mode](./multi
|
|||||||
2. Review bundled entries in **Bundled Plugins** and currently installed entries.
|
2. Review bundled entries in **Bundled Plugins** and currently installed entries.
|
||||||
3. Check each plugin’s status/state in the manager.
|
3. Check each plugin’s status/state in the manager.
|
||||||
|
|
||||||
First-party bundled entries include runtime plugins plus integrations like **Dependency Graph**, **Roadmap**, and **WhatsApp Chat**.
|
First-party bundled entries include runtime plugins plus integrations like **Dependency Graph**, **Roadmap**, **WhatsApp Chat**, and **CLI Printing Press**.
|
||||||
|
|
||||||
Expected outcome: You can see what is already installed, what is bundled and available, and each plugin’s current lifecycle state.
|
Expected outcome: You can see what is already installed, what is bundled and available, and each plugin’s current lifecycle state.
|
||||||
|
|
||||||
|
|||||||
@@ -130,6 +130,13 @@ const BUILTIN_PLUGINS: BuiltinPlugin[] = [
|
|||||||
category: "integration",
|
category: "integration",
|
||||||
path: "./plugins/fusion-plugin-whatsapp-chat",
|
path: "./plugins/fusion-plugin-whatsapp-chat",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
id: "fusion-plugin-cli-printing-press",
|
||||||
|
name: "CLI Printing Press",
|
||||||
|
description: "Guided wizard for drafting external service CLI definitions.",
|
||||||
|
category: "integration",
|
||||||
|
path: "./plugins/fusion-plugin-cli-printing-press",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
id: BUILTIN_AGENT_BROWSER_PLUGIN_ID,
|
id: BUILTIN_AGENT_BROWSER_PLUGIN_ID,
|
||||||
name: "Agent Browser",
|
name: "Agent Browser",
|
||||||
|
|||||||
@@ -268,6 +268,7 @@ describe("PluginManager", () => {
|
|||||||
expect(screen.getByText("Droid Runtime")).toBeTruthy();
|
expect(screen.getByText("Droid Runtime")).toBeTruthy();
|
||||||
expect(screen.getByText("Dependency Graph")).toBeTruthy();
|
expect(screen.getByText("Dependency Graph")).toBeTruthy();
|
||||||
expect(screen.getByText("WhatsApp Chat")).toBeTruthy();
|
expect(screen.getByText("WhatsApp Chat")).toBeTruthy();
|
||||||
|
expect(screen.getByText("CLI Printing Press")).toBeTruthy();
|
||||||
expect(screen.getByText(/Pairs to WhatsApp Web \(multi-device\) with QR or pairing code/i)).toBeTruthy();
|
expect(screen.getByText(/Pairs to WhatsApp Web \(multi-device\) with QR or pairing code/i)).toBeTruthy();
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -425,6 +426,26 @@ describe("PluginManager", () => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("installs CLI Printing Press from the built-in section", async () => {
|
||||||
|
render(<PluginManager addToast={addToast} />);
|
||||||
|
|
||||||
|
await waitFor(() => {
|
||||||
|
expect(fetchPlugins).toHaveBeenCalled();
|
||||||
|
});
|
||||||
|
|
||||||
|
const printingPressLabel = await screen.findByText("CLI Printing Press");
|
||||||
|
const printingPressCard = printingPressLabel.closest(".plugin-builtins-item");
|
||||||
|
expect(printingPressCard).toBeTruthy();
|
||||||
|
|
||||||
|
const installButton = within(printingPressCard as HTMLElement).getByRole("button", { name: /Install CLI Printing Press/i });
|
||||||
|
await userEvent.click(installButton);
|
||||||
|
|
||||||
|
await waitFor(() => {
|
||||||
|
expect(installPlugin).toHaveBeenCalledWith({ path: "./plugins/fusion-plugin-cli-printing-press" }, undefined);
|
||||||
|
expect(addToast).toHaveBeenCalledWith("CLI Printing Press installed globally", "success");
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
it("renders plugin list when plugins are available", async () => {
|
it("renders plugin list when plugins are available", async () => {
|
||||||
vi.mocked(fetchPlugins).mockResolvedValueOnce(mockPlugins);
|
vi.mocked(fetchPlugins).mockResolvedValueOnce(mockPlugins);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user