test(types): remove remaining testing barrel references

This commit is contained in:
Vincent Koc
2026-04-03 23:03:02 +09:00
parent 5341d483d1
commit 4b2c7404e5
14 changed files with 20 additions and 14 deletions

View File

@@ -1,5 +1,5 @@
import { isLiveTestEnabled } from "openclaw/plugin-sdk/testing";
import { describe, expect, it } from "vitest";
import { isLiveTestEnabled } from "../../src/agents/live-test-helpers.js";
import { transcribeDeepgramAudio } from "./audio.js";
const DEEPGRAM_KEY = process.env.DEEPGRAM_API_KEY ?? "";

View File

@@ -1,5 +1,5 @@
import type { PluginRuntime } from "openclaw/plugin-sdk/testing";
import { afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest";
import type { PluginRuntime } from "../../../src/plugins/runtime/types.js";
import { createStartAccountContext } from "../../../test/helpers/plugins/start-account-context.js";
import type { ResolvedDiscordAccount } from "./accounts.js";
import type { OpenClawConfig } from "./runtime-api.js";

View File

@@ -1,5 +1,5 @@
import type { MockFn } from "openclaw/plugin-sdk/testing";
import { vi } from "vitest";
import type { MockFn } from "../../../src/test-utils/vitest-mock-fn.js";
export const sendMock: MockFn = vi.fn();
export const reactMock: MockFn = vi.fn();

View File

@@ -1,5 +1,5 @@
import type { MockFn } from "openclaw/plugin-sdk/testing";
import { vi } from "vitest";
import type { MockFn } from "../../../../src/test-utils/vitest-mock-fn.js";
export const preflightDiscordMessageMock: MockFn = vi.fn();
export const processDiscordMessageMock: MockFn = vi.fn();

View File

@@ -1,5 +1,5 @@
import type { MockFn } from "openclaw/plugin-sdk/testing";
import { vi } from "vitest";
import type { MockFn } from "../../../src/test-utils/vitest-mock-fn.js";
type DiscordWebMediaMockFactoryResult = {
loadWebMedia: MockFn;

View File

@@ -7,7 +7,10 @@ export type {
export { clearAccountEntryFields } from "openclaw/plugin-sdk/core";
export { buildChannelConfigSchema } from "openclaw/plugin-sdk/channel-config-schema";
export type { ReplyPayload } from "openclaw/plugin-sdk/reply-runtime";
export type { ChannelAccountSnapshot, ChannelGatewayContext } from "openclaw/plugin-sdk/testing";
export type {
ChannelAccountSnapshot,
ChannelGatewayContext,
} from "../../src/channels/plugins/types.js";
export type { ChannelStatusIssue } from "openclaw/plugin-sdk/channel-contract";
export {
buildComputedAccountStatusSnapshot,

View File

@@ -10,7 +10,10 @@ export type {
export { clearAccountEntryFields } from "openclaw/plugin-sdk/core";
export { buildChannelConfigSchema } from "openclaw/plugin-sdk/channel-config-schema";
export type { ReplyPayload } from "openclaw/plugin-sdk/reply-runtime";
export type { ChannelAccountSnapshot, ChannelGatewayContext } from "openclaw/plugin-sdk/testing";
export type {
ChannelAccountSnapshot,
ChannelGatewayContext,
} from "../../src/channels/plugins/types.js";
export type { ChannelStatusIssue } from "openclaw/plugin-sdk/channel-contract";
export type { ChannelSetupDmPolicy, ChannelSetupWizard } from "openclaw/plugin-sdk/setup";
export {

View File

@@ -3,8 +3,8 @@ import fs from "node:fs/promises";
import net from "node:net";
import os from "node:os";
import path from "node:path";
import { createSandboxTestContext } from "openclaw/plugin-sdk/testing";
import { describe, expect, it } from "vitest";
import { createSandboxTestContext } from "../../../src/agents/sandbox/test-fixtures.js";
import {
createSandboxBrowserConfig,
createSandboxPruneConfig,

View File

@@ -1,5 +1,5 @@
import type { MockFn } from "openclaw/plugin-sdk/testing";
import { beforeEach, vi } from "vitest";
import type { MockFn } from "../../../src/test-utils/vitest-mock-fn.js";
import type { SignalDaemonExitEvent, SignalDaemonHandle } from "./daemon.js";
type SignalToolResultTestMocks = {

View File

@@ -2,8 +2,8 @@ import type { OpenClawConfig } from "openclaw/plugin-sdk/config-runtime";
import type { ChannelGroupPolicy } from "openclaw/plugin-sdk/config-runtime";
import type { TelegramAccountConfig } from "openclaw/plugin-sdk/config-runtime";
import type { RuntimeEnv } from "openclaw/plugin-sdk/runtime-env";
import type { MockFn } from "openclaw/plugin-sdk/testing";
import { vi } from "vitest";
import type { MockFn } from "../../../src/test-utils/vitest-mock-fn.js";
import { createNativeCommandTestParams } from "./bot-native-commands.fixture-test-support.js";
import type { RegisterTelegramNativeCommandsParams } from "./bot-native-commands.js";
import { registerTelegramNativeCommands } from "./bot-native-commands.js";

View File

@@ -7,8 +7,8 @@ import {
type MsgContext,
type ReplyPayload,
} from "openclaw/plugin-sdk/reply-runtime";
import type { MockFn } from "openclaw/plugin-sdk/testing";
import { beforeEach, vi } from "vitest";
import type { MockFn } from "../../../src/test-utils/vitest-mock-fn.js";
import type { TelegramBotDeps } from "./bot-deps.js";
type AnyMock = ReturnType<typeof vi.fn>;

View File

@@ -1,6 +1,6 @@
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-runtime";
import type { PluginRuntime } from "openclaw/plugin-sdk/testing";
import { afterEach, describe, expect, it, vi } from "vitest";
import type { PluginRuntime } from "../../../src/plugins/runtime/types.js";
import { createStartAccountContext } from "../../../test/helpers/plugins/start-account-context.js";
import type { ResolvedTelegramAccount } from "./accounts.js";
import * as auditModule from "./audit.js";

View File

@@ -5,8 +5,8 @@ import {
kindFromMime,
normalizePollInput,
} from "openclaw/plugin-sdk/media-runtime";
import type { MockFn } from "openclaw/plugin-sdk/testing";
import { beforeEach, vi } from "vitest";
import type { MockFn } from "../../../src/test-utils/vitest-mock-fn.js";
const { botApi, botCtorSpy } = vi.hoisted(() => ({
botApi: {

View File

@@ -1,5 +1,5 @@
import type { OpenClawConfig } from "openclaw/plugin-sdk/testing";
import { beforeEach, describe, expect, it, vi } from "vitest";
import type { OpenClawConfig } from "../../../src/config/config.js";
export const readConfigFileSnapshotForWrite = vi.fn();
export const writeConfigFile = vi.fn();