refactor: expose plugin test helpers via sdk

This commit is contained in:
Peter Steinberger
2026-04-27 23:45:08 +01:00
parent 6f09039b0c
commit 0df6e5a473
126 changed files with 659 additions and 349 deletions

View File

@@ -1,8 +1,11 @@
import { EventEmitter } from "node:events";
import type { IncomingMessage } from "node:http";
import { createEmptyPluginRegistry, setActivePluginRegistry } from "openclaw/plugin-sdk/testing";
import {
createEmptyPluginRegistry,
createMockServerResponse,
setActivePluginRegistry,
} from "openclaw/plugin-sdk/testing";
import { afterEach, describe, expect, it, vi } from "vitest";
import { createMockServerResponse } from "../../../test/helpers/plugins/mock-http-response.js";
import type { OpenClawConfig, PluginRuntime } from "../runtime-api.js";
import type { ResolvedGoogleChatAccount } from "./accounts.js";
import { verifyGoogleChatRequest } from "./auth.js";

View File

@@ -1,12 +1,12 @@
import { DEFAULT_ACCOUNT_ID } from "openclaw/plugin-sdk/setup";
import { afterEach, describe, expect, it, vi } from "vitest";
import {
createPluginSetupWizardConfigure,
createPluginSetupWizardStatus,
createTestWizardPrompter,
runSetupWizardConfigure,
type WizardPrompter,
} from "../../../test/helpers/plugins/setup-wizard.js";
} from "openclaw/plugin-sdk/testing";
import { afterEach, describe, expect, it, vi } from "vitest";
import {
expectLifecyclePatch,
expectPendingUntilAbort,