mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-07 14:31:24 +00:00
Auth choice tests: assert env-backed keyRef persistence
This commit is contained in:
committed by
Peter Steinberger
parent
58590087de
commit
56f73ae080
@@ -44,7 +44,7 @@ describe("applyAuthChoiceMiniMax", () => {
|
|||||||
|
|
||||||
async function readAuthProfiles(agentDir: string) {
|
async function readAuthProfiles(agentDir: string) {
|
||||||
return await readAuthProfilesForAgent<{
|
return await readAuthProfilesForAgent<{
|
||||||
profiles?: Record<string, { key?: string }>;
|
profiles?: Record<string, { key?: string; keyRef?: { source: string; id: string } }>;
|
||||||
}>(agentDir);
|
}>(agentDir);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -154,7 +154,10 @@ describe("applyAuthChoiceMiniMax", () => {
|
|||||||
expect(confirm).toHaveBeenCalled();
|
expect(confirm).toHaveBeenCalled();
|
||||||
|
|
||||||
const parsed = await readAuthProfiles(agentDir);
|
const parsed = await readAuthProfiles(agentDir);
|
||||||
expect(parsed.profiles?.["minimax-cn:default"]?.key).toBe("mm-env-token");
|
expect(parsed.profiles?.["minimax-cn:default"]?.keyRef).toEqual({
|
||||||
|
source: "env",
|
||||||
|
id: "MINIMAX_API_KEY",
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
it("uses minimax-api-lightning default model", async () => {
|
it("uses minimax-api-lightning default model", async () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user