You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test(e2e): replace per-provider add-flow tests with representative journeys and registry contract tests #989
apps/desktop/e2e/providers.spec.ts has grown to 42 executed tests, 30+ of which are copies of one template: open Settings → catalog → tab → search → open provider → assert form defaults → save → assert detail. The only difference between the copies is registry data (slug, base URL, default model, catalog group, brand mark) — the code path they exercise is identical.
This verifies pure PROVIDER_DEFAULTS facts through the most expensive vehicle available. Every provider adds a real Electron window launch/teardown, so suite time (~4 min) and the teardown-flake surface grow linearly with the catalog — see the Tearing down "window" exceeded the test timeout failure on #988, an infrastructure hang in one of the 42 windows, unrelated to the change under test. The pattern contradicts AGENTS.md ("cover one representative journey rather than every variation") and keeps propagating: each new provider PR copies the previous test (most recently #944, #978).
Desired outcome
providers.spec.ts runs a single-digit number of tests: one representative API-key add journey end to end, the keyboard-focus restore case, and one variant per genuinely different behavior (OAuth/gated providers, local runtimes) — not one per provider.
Per-provider facts (slug, base URL, default model, catalog group, official color mark asset exists) are covered by a data-driven contract test iterating PROVIDER_DEFAULTS, which fails when a provider is added without coverage. The registry-derived conformance matrix from feat(core): derive provider conformance matrix from registry declarations #974 is the natural seam.
The colorAssetRenderContract mechanism (brand mark renders as a color asset) is verified once in E2E; per-provider asset presence becomes a static check.
Adding a provider no longer adds an Electron window to CI, and the convention is written down where provider PR authors will see it (AGENTS.md or the spec file header), so the copy-paste pattern stops reproducing.
Alternatives or workarounds
Keep the status quo and only harden window teardown: reduces flake but suite time and per-provider cost keep growing linearly, and the data assertions stay in the wrong layer.
Parallelize/shard the E2E job: hides the wall-clock symptom, pays the same compute, and does nothing about the flake surface or the propagating pattern.
Activity
fix(settings): lowercase provider type before deriving the default slug
test(core): align provider catalog contract with production gates
test(desktop): add default slug derivation contract
test(core): add provider catalog registry invariants
test(desktop): consolidate per-provider add-flow E2E into representat…
test(core): drop redundant default-model assertions
fix(settings): lowercase provider type before deriving the default slug
test(core): align provider catalog contract with production gates
test(desktop): add default slug derivation contract
fix(settings): make nextSlug collision search unbounded
test(core): stop treating blank registry baseUrl as a concrete endpoint
test(e2e): replace per-provider add-flow tests with representative jo…