Download extensions/plugin-entry.cli-laziness.test.ts from SaylorTwift/openclaw: direct link, hf CLI and curl.
- Browser
- Download file 826 Bytes
-
https://huggingface.co/SaylorTwift/openclaw/resolve/main/extensions/plugin-entry.cli-laziness.test.ts
- Command line
-
hf download hf://SaylorTwift/openclaw/extensions/plugin-entry.cli-laziness.test.ts
-
curl -L -o plugin-entry.cli-laziness.test.ts https://huggingface.co/SaylorTwift/openclaw/resolve/main/extensions/plugin-entry.cli-laziness.test.ts
826 Bytes
| import { expect, it, vi } from "vitest"; | |
| vi.mock("./memory-wiki/src/cli.js", () => { | |
| throw new Error("memory-wiki CLI eagerly imported"); | |
| }); | |
| vi.mock("./policy/src/cli.js", () => { | |
| throw new Error("policy CLI eagerly imported"); | |
| }); | |
| vi.mock("./qa-lab/src/cli.js", () => { | |
| throw new Error("qa-lab CLI eagerly imported"); | |
| }); | |
| vi.mock("./voice-call/src/cli.js", () => { | |
| throw new Error("voice-call CLI eagerly imported"); | |
| }); | |
| it.each([ | |
| { id: "memory-wiki", load: () => import("./memory-wiki/index.js") }, | |
| { id: "policy", load: () => import("./policy/index.js") }, | |
| { id: "qa-lab", load: () => import("./qa-lab/index.js") }, | |
| { id: "voice-call", load: () => import("./voice-call/index.js") }, | |
| ])("imports $id without evaluating its CLI", async ({ id, load }) => { | |
| expect((await load()).default.id).toBe(id); | |
| }); | |