-
[NA] [QA] test(e2e): fall through to an offered provider when configuring models (#7324)
发布于
2026-07-06 14:10:10 +00:00 - [NA] [QA] test(e2e): fall through to an offered provider when configuring models
The ensureModelAvailable helpers picked an LLM provider by which API key the
runner has, then committed to it — so a runner with ANTHROPIC_API_KEY always
tried Anthropic even on deployments that don't offer it (restricted envs expose
only a subset of providers). The add-provider dialog never renders that option,
so the click hung for 15s and failed the playground / test-suites / online-eval
t1 smokes.ensureProviderConfigured now probes whether the provider option is actually
offered in the dialog and returns false (falling through) instead of hanging.
The five duplicated ensureModelAvailable copies are consolidated into a single
pom/model-availability.ts that tries Anthropic -> OpenAI -> OpenRouter (Custom
Provider), skipping any candidate the deployment doesn't offer.Co-Authored-By: Claude Opus 4.8 noreply@anthropic.com
- test(e2e): address review — step-wrap POM methods, guard custom-provider fallback
- ensureProviderConfigured / ensureCustomProviderConfigured now wrap their
bodies in test.step() and return through the callback (POM instrumentation
convention), so the trace/Allure timeline stays legible. - ensureCustomProviderConfigured probes whether the Custom option is offered
(bounded 2s wait) and returns boolean, mirroring ensureProviderConfigured —
so a deployment with the custom-llm toggle off falls through instead of
hanging on a missing option. - Dropped the unbounded "first option visible" wait in ensureProviderConfigured;
the per-provider bounded probe already handles an empty option grid (all
toggles off) without a 30s hang. - ensureModelAvailable consumes the custom method's boolean and skips cleanly
when no candidate provider is offered. - playground-providers.spec skips when the provider under test isn't offered
rather than proceeding to a model selection that can't resolve.
Co-Authored-By: Claude Opus 4.8 noreply@anthropic.com
Co-authored-by: Claude Opus 4.8 noreply@anthropic.com
下载附件