Add Playwright OIDC integration tests using local Dex provider#41
Draft
Add Playwright OIDC integration tests using local Dex provider#41
Conversation
Co-authored-by: 9SMTM6 <44668330+9SMTM6@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add Playwright-based OIDC integration tests for Dex
Add Playwright OIDC integration tests using local Dex provider
Mar 19, 2026
Owner
|
@copilot please add a CI job for these tests, so that you can iterate independently in this PR. |
Co-authored-by: 9SMTM6 <44668330+9SMTM6@users.noreply.github.com>
Author
Added in b442904. The new
It's also wired into |
Owner
|
goddamnit, it cant iterate on that independently like that. If it doesn't react to CI failures either IDK how this would be better than a local agent in any way, since it needs pretty much the same amount of looking after while progressing. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a self-contained Playwright test harness for the OIDC authorization code flow using a real Dex v2 identity provider. Tests are intentionally small and local-first; OIDC is currently broken server-side so the login flow test is expected to fail until that is fixed.
Provider (
tests/oidc-integration/providers/dex/)docker-compose.yaml— runsghcr.io/dexidp/dex:v2.41.1on port 5556config.yaml— in-memory storage, static passwordtestuser@example.com/password, clientshuthost-test/shuthost-test-secret, redirect tohttps://127.0.0.1:18080/oidc/callback,skipApprovalScreen: trueHarness (
tests/oidc-integration/)global-setup.ts— builds coordinator (respectsSKIP_BUILD), generates a self-signed cert viaopensslintocerts/(idempotent), starts Dex viadocker compose up -d --wait, polls/.well-known/openid-configuration, fillsconfigs/coordinator-dex.tmpl.tomlwith runtime values, and spawns the coordinator on port 18080global-teardown.ts— kills coordinator and runsdocker compose down(runs even on test failure)helpers/dex.ts—loginWithDex(page, baseUrl)fills credentials and defensively handles the optional grant screenspecs/dex.spec.ts— three tests: Dex discovery sanity check, full login redirect flow, and error/deny callback handlingconfigs/coordinator-dex.tmpl.toml— coordinator config template with{{COORD_PORT}},{{DEX_PORT}},{{CERT_PATH}},{{KEY_PATH}}placeholdersJustfile
CI (
.github/workflows/main.yaml)A new
oidc-integration-testsjob:SKIP_BUILD=1and--reporter=linetarget/playwright-oidc-test-resultsas artifacts (even on failure)The job is wired into
tests-aggregateandrelease-needs-flattenedso it runs alongside the rest of CI and gates releases.Generated files (
certs/, filled config,node_modules, reports) are gitignored.Original prompt
Created from VS Code.
📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.