mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-28 03:53:54 +00:00
fix: align sqlite branch with main
This commit is contained in:
@@ -305,7 +305,7 @@ describe("resolveAuthProfileOrder", () => {
|
||||
expect(order).toEqual([]);
|
||||
});
|
||||
|
||||
it("preserves native Codex profiles before OpenAI alias API-key order", async () => {
|
||||
it("respects friendly OpenAI alias API-key order when Codex auth is selected", async () => {
|
||||
const store: AuthProfileStore = {
|
||||
version: 1,
|
||||
profiles: {
|
||||
@@ -336,7 +336,7 @@ describe("resolveAuthProfileOrder", () => {
|
||||
provider: "openai-codex",
|
||||
});
|
||||
|
||||
expect(order).toEqual(["openai-codex:personal", "openai:default"]);
|
||||
expect(order).toEqual(["openai:default"]);
|
||||
});
|
||||
|
||||
it("keeps Codex profiles listed in the friendly OpenAI order for Codex auth", async () => {
|
||||
|
||||
@@ -373,9 +373,8 @@ describe("runEmbeddedPiAgent", () => {
|
||||
expect(ensureOpenClawModelCatalogMock).not.toHaveBeenCalled();
|
||||
});
|
||||
|
||||
it("resolves explicit OpenAI OpenClaw runs through Codex when auth order starts with Codex OAuth", async () => {
|
||||
const sessionFile = nextSessionFile();
|
||||
const baseConfig = createEmbeddedAgentRunnerOpenAiConfig(["mock-1"]);
|
||||
it("resolves explicit OpenAI PI runs through Codex when auth order starts with Codex OAuth", async () => {
|
||||
const baseConfig = createEmbeddedPiRunnerOpenAiConfig(["mock-1"]);
|
||||
const openAIProvider = baseConfig.models?.providers?.openai;
|
||||
if (!openAIProvider) {
|
||||
throw new Error("expected OpenAI provider test config");
|
||||
@@ -414,9 +413,8 @@ describe("runEmbeddedPiAgent", () => {
|
||||
}),
|
||||
);
|
||||
|
||||
await runEmbeddedAgent({
|
||||
sessionId: "codex-first-openclaw",
|
||||
sessionFile,
|
||||
await runEmbeddedPiAgent({
|
||||
sessionId: "codex-first-pi",
|
||||
workspaceDir,
|
||||
config: cfg,
|
||||
prompt: "hello",
|
||||
|
||||
@@ -88,7 +88,6 @@ import {
|
||||
shouldPreferExplicitConfigApiKeyAuth,
|
||||
} from "../model-auth.js";
|
||||
import { ensureOpenClawModelCatalog } from "../models-config.js";
|
||||
import { resolveContextConfigProviderForRuntime } from "../openai-codex-routing.js";
|
||||
import {
|
||||
OPENAI_CODEX_PROVIDER_ID,
|
||||
listOpenAIAuthProfileProvidersForAgentRuntime,
|
||||
|
||||
Reference in New Issue
Block a user