refactor(test): dedupe setup wizard helpers

This commit is contained in:
Peter Steinberger
2026-03-22 00:15:51 +00:00
parent 85722d4cf2
commit 30ad059da8
27 changed files with 322 additions and 186 deletions

View File

@@ -1,6 +1,6 @@
import { describe, expect, it, vi } from "vitest";
import {
createPluginSetupWizardAdapter,
createPluginSetupWizardConfigure,
createTestWizardPrompter,
runSetupWizardConfigure,
type WizardPrompter,
@@ -8,7 +8,7 @@ import {
import type { OpenClawConfig } from "../api.js";
import { tlonPlugin } from "./channel.js";
const tlonConfigureAdapter = createPluginSetupWizardAdapter(tlonPlugin);
const tlonConfigure = createPluginSetupWizardConfigure(tlonPlugin);
describe("tlon setup wizard", () => {
it("configures ship, auth, and discovery settings", async () => {
@@ -46,7 +46,7 @@ describe("tlon setup wizard", () => {
});
const result = await runSetupWizardConfigure({
configure: tlonConfigureAdapter.configure,
configure: tlonConfigure,
cfg: {} as OpenClawConfig,
prompter,
options: {},