mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-26 12:26:38 -06:00
b5b17c654b
* fix(ui): keep workboard in sidebar navigation * test(ui): align workboard navigation ownership * fix(ui): preserve saved workboard sidebar slots * test(ui): shrink assertion safety baseline * fix(plugins): bind native routes to bundled owners * refactor(plugins): isolate native route policy
29 lines
802 B
TypeScript
29 lines
802 B
TypeScript
import { capturePluginRegistration } from "openclaw/plugin-sdk/plugin-test-runtime";
|
|
import { describe, expect, it, vi } from "vitest";
|
|
|
|
vi.mock("./src/store.js", () => ({
|
|
WorkboardStore: { openSqlite: () => ({}) },
|
|
}));
|
|
|
|
import plugin from "./index.js";
|
|
|
|
describe("Workboard plugin registration", () => {
|
|
it("advertises its native route only while the plugin runtime is active", () => {
|
|
const captured = capturePluginRegistration({
|
|
id: "workboard",
|
|
name: "Workboard",
|
|
register: plugin.register,
|
|
});
|
|
|
|
expect(captured.controlUiDescriptors).toContainEqual({
|
|
surface: "tab",
|
|
id: "workboard",
|
|
label: "Workboard",
|
|
placement: "route:workboard",
|
|
icon: "kanban",
|
|
group: "control",
|
|
requiredScopes: ["operator.read"],
|
|
});
|
|
});
|
|
});
|