{{ message }}
feat(markdown): add Playwright visual + functional e2e for the demo shell#73477
Open
stephenliang wants to merge 2 commits into
Open
feat(markdown): add Playwright visual + functional e2e for the demo shell#73477stephenliang wants to merge 2 commits into
stephenliang wants to merge 2 commits into
Conversation
…hell
Re-introduce visual coverage to the markdown package (its vitest-browser
harness was removed earlier in the branch) via the shared
@code-dot-org/playwright-support — the abstraction's first non-lab consumer.
- e2e/fixtures/visual.ts — createVisualTest({appName: 'Code.org Markdown'})
- e2e/poms/DemoPage.ts — POM for the demo shell (scenario picker, dark-mode
toggle, preview)
- e2e/demo.spec.ts — functional checks (picker renders, default scenario,
scenario switch, dark-mode theme flip, sanitization strips scripts)
- e2e/visual.spec.ts — an @visual checkpoint per scenario in light and dark
(24 total); baselines live in Applitools, none committed
- playwright.config.ts — chromium functional project + visualProjects()
- package.json — test:ui / test:ui:ci / test:visual:prove + playwright and
@code-dot-org/playwright-support deps
- vitest.config.ts — exclude e2e/** so Vitest ignores the Playwright specs
- .gitignore — playwright-report, test-results, e2e/tmp
CI: add .github/workflows/markdown-ci.yml (mirrors oceans-ci: build + e2e
with VISUAL_PROVIDER=applitools) and wire it into frontend-ci.yml — a
paths-filter output and filter, a conditional job passing
playwright-image-tag, and the teardown.needs entry.
Verified: typecheck, lint, 43 unit tests, and build pass; Playwright
resolves the package for both functional (5) and @visual (24) specs;
locators authored against the demo DOM (data-testid + DSCO Toggle role
confirmed from source). The live browser run is deferred — the shared
sandbox OOM-kills the render under concurrent load (BROWSER DISCONNECTED,
no JS error; about:blank and oceans rendered fine) — it runs in
markdown-ci's isolated container, and the mechanism was captured live
against oceans.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- CI paths-filter: add playwright-support/** to markdown filter.
- markdown-ci.yml: add Install LFS step to match oceans-ci.
- DemoPage: check()/setChecked() use {force: true} for DSCO
opacity:0 input overlays.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.

Summary
Adds Playwright e2e tests for the markdown demo shell, consuming
@code-dot-org/playwright-supportfrom #73476.markdown-ci.yml— new GHA workflow (mirrors oceans-ci pattern).playwright-support/**added to markdown filter.Test plan
turbo run build typecheckgreen for markdownDeploy notes
No deployment changes.
🤖 Generated with Claude Code