mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 15:38:25 +00:00
refactor(onboard): unify auth-choice aliases and provider flags
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import type { AuthProfileStore } from "../agents/auth-profiles.js";
|
||||
import { buildAuthChoiceOptions, formatAuthChoiceChoicesForCli } from "./auth-choice-options.js";
|
||||
import {
|
||||
buildAuthChoiceGroups,
|
||||
buildAuthChoiceOptions,
|
||||
formatAuthChoiceChoicesForCli,
|
||||
} from "./auth-choice-options.js";
|
||||
|
||||
describe("buildAuthChoiceOptions", () => {
|
||||
it("includes GitHub Copilot", () => {
|
||||
@@ -172,4 +176,16 @@ describe("buildAuthChoiceOptions", () => {
|
||||
expect(cliChoices).toContain("claude-cli");
|
||||
expect(cliChoices).toContain("codex-cli");
|
||||
});
|
||||
|
||||
it("shows Chutes in grouped provider selection", () => {
|
||||
const store: AuthProfileStore = { version: 1, profiles: {} };
|
||||
const { groups } = buildAuthChoiceGroups({
|
||||
store,
|
||||
includeSkip: false,
|
||||
});
|
||||
const chutesGroup = groups.find((group) => group.value === "chutes");
|
||||
|
||||
expect(chutesGroup).toBeDefined();
|
||||
expect(chutesGroup?.options.some((opt) => opt.value === "chutes")).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user