mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-25 03:45:46 -06:00
b9dda9d740
* fix(diffs): load Playwright renderer on demand * style(diffs): format lazy renderer construction * fix(diffs): keep viewer mode free of Playwright * fix(diffs): preserve viewer fallback on renderer load failure * test(diffs): satisfy result narrowing lint * refactor(diffs): centralize lazy renderer runtime
12 lines
349 B
TypeScript
12 lines
349 B
TypeScript
import { expect, it, vi } from "vitest";
|
|
|
|
vi.mock("./src/browser.runtime.js", () => {
|
|
throw new Error("plugin startup must not load the Playwright renderer");
|
|
});
|
|
|
|
it("imports the plugin entry without loading the Playwright renderer", async () => {
|
|
const { default: plugin } = await import("./index.js");
|
|
|
|
expect(plugin.id).toBe("diffs");
|
|
});
|