mirror of
https://github.com/bitbaum/openclaw.git
synced 2026-12-03 20:07:19 +01:00
test(codex): cover opaque model IDs in native discovery (#132144)
This commit is contained in:
1 parent
50d229fe47
commit
a79e6517be
1 file changed
+29
-23
@@ -239,30 +239,36 @@ describe("Codex agent harness supports()", () => {
|
||||
expect(!result.supported ? result.reason : undefined).toContain("not declared");
|
||||
});
|
||||
|
||||
it("lets explicitly selected Codex discover unlisted models with its own account", () => {
|
||||
expect(
|
||||
harness.supports({
|
||||
provider: "openai",
|
||||
modelId: "gpt-future",
|
||||
requestedRuntime: "codex",
|
||||
modelProvider: {
|
||||
requestTransportOverrides: "none",
|
||||
preparedAuth: { source: "harness" },
|
||||
},
|
||||
}),
|
||||
).toEqual({ supported: true, priority: 100 });
|
||||
});
|
||||
it.each(["gpt-future", "umbreon-latest"])(
|
||||
"lets explicitly selected Codex discover %s with its own account",
|
||||
(modelId) => {
|
||||
expect(
|
||||
harness.supports({
|
||||
provider: "openai",
|
||||
modelId,
|
||||
requestedRuntime: "codex",
|
||||
modelProvider: {
|
||||
requestTransportOverrides: "none",
|
||||
preparedAuth: { source: "harness" },
|
||||
},
|
||||
}),
|
||||
).toEqual({ supported: true, priority: 100 });
|
||||
},
|
||||
);
|
||||
|
||||
it("lets explicit Codex model discovery run before auth has been prepared", () => {
|
||||
expect(
|
||||
harness.supports({
|
||||
provider: "openai",
|
||||
modelId: "gpt-future",
|
||||
requestedRuntime: "codex",
|
||||
modelProvider: { requestTransportOverrides: "none" },
|
||||
}),
|
||||
).toEqual({ supported: true, priority: 100 });
|
||||
});
|
||||
it.each(["gpt-future", "umbreon-latest"])(
|
||||
"lets explicit Codex discovery of %s run before auth has been prepared",
|
||||
(modelId) => {
|
||||
expect(
|
||||
harness.supports({
|
||||
provider: "openai",
|
||||
modelId,
|
||||
requestedRuntime: "codex",
|
||||
modelProvider: { requestTransportOverrides: "none" },
|
||||
}),
|
||||
).toEqual({ supported: true, priority: 100 });
|
||||
},
|
||||
);
|
||||
|
||||
it.each([
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user