style(line): format files to unblock ci check

This commit is contained in:
Peter Steinberger
2026-02-16 03:39:41 +00:00
parent b5a63e18f9
commit 702b94fe8f
3 changed files with 8 additions and 8 deletions

View File

@@ -26,11 +26,7 @@ function createRuntime() {
return { runtime, probeLineBot, monitorLineProvider };
}
function createStartAccountCtx(params: {
token: string;
secret: string;
runtime: unknown;
}) {
function createStartAccountCtx(params: { token: string; secret: string; runtime: unknown }) {
return {
account: {
accountId: "default",
@@ -58,7 +54,9 @@ describe("linePlugin gateway.startAccount", () => {
runtime: {},
}) as never,
),
).rejects.toThrow('LINE webhook mode requires a non-empty channel secret for account "default".');
).rejects.toThrow(
'LINE webhook mode requires a non-empty channel secret for account "default".',
);
expect(monitorLineProvider).not.toHaveBeenCalled();
});

View File

@@ -604,7 +604,9 @@ export const linePlugin: ChannelPlugin<ResolvedLineAccount> = {
probeAccount: async ({ account, timeoutMs }) =>
getLineRuntime().channel.line.probeLineBot(account.channelAccessToken, timeoutMs),
buildAccountSnapshot: ({ account, runtime, probe }) => {
const configured = Boolean(account.channelAccessToken?.trim() && account.channelSecret?.trim());
const configured = Boolean(
account.channelAccessToken?.trim() && account.channelSecret?.trim(),
);
return {
accountId: account.accountId,
name: account.name,

View File

@@ -1,6 +1,6 @@
import { describe, expect, it } from "vitest";
import type { OpenClawConfig } from "../config/config.js";
import type { RuntimeEnv } from "../runtime.js";
import { describe, expect, it } from "vitest";
import { monitorLineProvider } from "./monitor.js";
describe("monitorLineProvider fail-closed webhook auth", () => {