mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-02 18:30:22 +00:00
style(format): fix provider test formatting drift
This commit is contained in:
@@ -53,9 +53,7 @@ describe("nextcloud talk setup core", () => {
|
||||
},
|
||||
});
|
||||
|
||||
expect(
|
||||
clearNextcloudTalkAccountFields(cfg, DEFAULT_ACCOUNT_ID, ["botSecret"]),
|
||||
).toMatchObject({
|
||||
expect(clearNextcloudTalkAccountFields(cfg, DEFAULT_ACCOUNT_ID, ["botSecret"])).toMatchObject({
|
||||
channels: {
|
||||
"nextcloud-talk": {
|
||||
baseUrl: "https://cloud.example.com",
|
||||
@@ -72,18 +70,19 @@ describe("nextcloud talk setup core", () => {
|
||||
},
|
||||
});
|
||||
|
||||
expect(clearNextcloudTalkAccountFields(cfg, "work", ["botSecret", "botSecretFile"]))
|
||||
.toMatchObject({
|
||||
channels: {
|
||||
"nextcloud-talk": {
|
||||
accounts: {
|
||||
work: {
|
||||
apiPassword: "api-secret",
|
||||
},
|
||||
expect(
|
||||
clearNextcloudTalkAccountFields(cfg, "work", ["botSecret", "botSecretFile"]),
|
||||
).toMatchObject({
|
||||
channels: {
|
||||
"nextcloud-talk": {
|
||||
accounts: {
|
||||
work: {
|
||||
apiPassword: "api-secret",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
},
|
||||
});
|
||||
});
|
||||
|
||||
it("sets top-level DM policy state", async () => {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
|
||||
import { openaiMediaUnderstandingProvider } from "./media-understanding-provider.js";
|
||||
import { buildOpenAIImageGenerationProvider } from "./image-generation-provider.js";
|
||||
import { openaiMediaUnderstandingProvider } from "./media-understanding-provider.js";
|
||||
import { buildOpenAICodexProviderPlugin } from "./openai-codex-provider.js";
|
||||
import { buildOpenAIProvider } from "./openai-provider.js";
|
||||
import { buildOpenAISpeechProvider } from "./speech-provider.js";
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { afterEach, describe, expect, it, vi } from "vitest";
|
||||
import * as modelAuth from "../../agents/model-auth.js";
|
||||
import { buildFalImageGenerationProvider } from "../../../extensions/fal/image-generation-provider.js";
|
||||
import * as modelAuth from "../../agents/model-auth.js";
|
||||
|
||||
function expectFalJsonPost(
|
||||
fetchMock: ReturnType<typeof vi.fn>,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { afterEach, describe, expect, it, vi } from "vitest";
|
||||
import * as modelAuth from "../../agents/model-auth.js";
|
||||
import { buildGoogleImageGenerationProvider } from "../../../extensions/google/image-generation-provider.js";
|
||||
import * as modelAuth from "../../agents/model-auth.js";
|
||||
|
||||
describe("Google image-generation provider", () => {
|
||||
afterEach(() => {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { afterEach, describe, expect, it, vi } from "vitest";
|
||||
import * as modelAuth from "../../agents/model-auth.js";
|
||||
import { buildOpenAIImageGenerationProvider } from "../../../extensions/openai/image-generation-provider.js";
|
||||
import * as modelAuth from "../../agents/model-auth.js";
|
||||
|
||||
describe("OpenAI image-generation provider", () => {
|
||||
afterEach(() => {
|
||||
|
||||
@@ -165,8 +165,10 @@ describe("applyMediaUnderstanding – echo transcript", () => {
|
||||
}));
|
||||
vi.doMock("./providers/index.js", async (importOriginal) => {
|
||||
const actual = await importOriginal<typeof import("./providers/index.js")>();
|
||||
const { deepgramProvider } = await import("../../extensions/deepgram/media-understanding-provider.js");
|
||||
const { groqProvider } = await import("../../extensions/groq/media-understanding-provider.js");
|
||||
const { deepgramProvider } =
|
||||
await import("../../extensions/deepgram/media-understanding-provider.js");
|
||||
const { groqProvider } =
|
||||
await import("../../extensions/groq/media-understanding-provider.js");
|
||||
return {
|
||||
...actual,
|
||||
buildMediaUnderstandingRegistry: (
|
||||
|
||||
@@ -248,8 +248,10 @@ describe("applyMediaUnderstanding", () => {
|
||||
}));
|
||||
vi.doMock("./providers/index.js", async (importOriginal) => {
|
||||
const actual = await importOriginal<typeof import("./providers/index.js")>();
|
||||
const { deepgramProvider } = await import("../../extensions/deepgram/media-understanding-provider.js");
|
||||
const { groqProvider } = await import("../../extensions/groq/media-understanding-provider.js");
|
||||
const { deepgramProvider } =
|
||||
await import("../../extensions/deepgram/media-understanding-provider.js");
|
||||
const { groqProvider } =
|
||||
await import("../../extensions/groq/media-understanding-provider.js");
|
||||
return {
|
||||
...actual,
|
||||
buildMediaUnderstandingRegistry: (
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { isTruthyEnvValue } from "../../../infra/env.js";
|
||||
import { transcribeDeepgramAudio } from "../../../../extensions/deepgram/media-understanding-provider.js";
|
||||
import { isTruthyEnvValue } from "../../../infra/env.js";
|
||||
|
||||
const DEEPGRAM_KEY = process.env.DEEPGRAM_API_KEY ?? "";
|
||||
const DEEPGRAM_MODEL = process.env.DEEPGRAM_MODEL?.trim() || "nova-3";
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { transcribeDeepgramAudio } from "../../../../extensions/deepgram/media-understanding-provider.js";
|
||||
import {
|
||||
createAuthCaptureJsonFetch,
|
||||
createRequestCaptureJsonFetch,
|
||||
installPinnedHostnameTestHooks,
|
||||
} from "../audio.test-helpers.js";
|
||||
import { transcribeDeepgramAudio } from "../../../../extensions/deepgram/media-understanding-provider.js";
|
||||
|
||||
installPinnedHostnameTestHooks();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user