@@ -263,25 +263,26 @@ describe("buildAuthChoiceOptions", () => {
|
263 | 263 | ]); |
264 | 264 | const options = getOptions(); |
265 | 265 | |
266 | | -expect(options.map((option) => option.value)).toEqual( |
267 | | -expect.arrayContaining([ |
268 | | -"github-copilot", |
269 | | -"zai-api-key", |
270 | | -"xiaomi-api-key", |
271 | | -"minimax-global-api", |
272 | | -"moonshot-api-key", |
273 | | -"together-api-key", |
274 | | -"chutes", |
275 | | -"xai-api-key", |
276 | | -"mistral-api-key", |
277 | | -"volcengine-api-key", |
278 | | -"byteplus-api-key", |
279 | | -"vllm", |
280 | | -"opencode-go", |
281 | | -"ollama", |
282 | | -"sglang", |
283 | | -]), |
284 | | -); |
| 266 | +const optionValues = options.map((option) => option.value); |
| 267 | +for (const expectedValue of [ |
| 268 | +"github-copilot", |
| 269 | +"zai-api-key", |
| 270 | +"xiaomi-api-key", |
| 271 | +"minimax-global-api", |
| 272 | +"moonshot-api-key", |
| 273 | +"together-api-key", |
| 274 | +"chutes", |
| 275 | +"xai-api-key", |
| 276 | +"mistral-api-key", |
| 277 | +"volcengine-api-key", |
| 278 | +"byteplus-api-key", |
| 279 | +"vllm", |
| 280 | +"opencode-go", |
| 281 | +"ollama", |
| 282 | +"sglang", |
| 283 | +]) { |
| 284 | +expect(optionValues).toContain(expectedValue); |
| 285 | +} |
285 | 286 | }); |
286 | 287 | |
287 | 288 | it("builds cli help choices from the same runtime catalog", () => { |
@@ -519,9 +520,9 @@ describe("buildAuthChoiceOptions", () => {
|
519 | 520 | }); |
520 | 521 | const openCodeGroup = requireChoiceGroup(groups, "opencode"); |
521 | 522 | |
522 | | -expect(openCodeGroup.options.map((option) => option.value)).toEqual( |
523 | | - expect.arrayContaining(["opencode-zen", "opencode-go"]), |
524 | | -); |
| 523 | +const openCodeValues = openCodeGroup.options.map((option) => option.value); |
| 524 | +expect(openCodeValues).toContain("opencode-zen"); |
| 525 | +expect(openCodeValues).toContain("opencode-go"); |
525 | 526 | }); |
526 | 527 | |
527 | 528 | it("hides image-generation-only providers from the interactive auth picker", () => { |
@@ -565,7 +566,8 @@ describe("buildAuthChoiceOptions", () => {
|
565 | 566 | const options = getOptions(); |
566 | 567 | const optionValues = options.map((option) => option.value); |
567 | 568 | |
568 | | -expect(optionValues).toEqual(expect.arrayContaining(["openai-api-key", "ollama"])); |
| 569 | +expect(optionValues).toContain("openai-api-key"); |
| 570 | +expect(optionValues).toContain("ollama"); |
569 | 571 | expect(optionValues).not.toContain("fal-api-key"); |
570 | 572 | expect(optionValues).not.toContain("local-image-runtime"); |
571 | 573 | }); |
|