test: refactor to modules and accessible locators.#36
Merged
knightedcodemonkey merged 2 commits intomainfrom Mar 28, 2026
Merged
test: refactor to modules and accessible locators.#36knightedcodemonkey merged 2 commits intomainfrom
knightedcodemonkey merged 2 commits intomainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Refactors the existing monolithic Playwright e2e coverage into focused spec modules while shifting selectors toward accessibility-first locators. To support that, it adds/strengthens ARIA semantics in the app (status, panels, preview host, editor fallback) and exposes a way to apply ARIA attributes to the CodeMirror editor content.
Changes:
- Add ARIA roles/labels for status, panels, preview output region, and editor textarea fallbacks.
- Extend CodeMirror editor setup to optionally apply
contentAttributes(used to label the editor content for accessibility). - Split
playwright/app.spec.tsinto multiple spec files + shared helper utilities and document the selector conventions inAGENTS.md.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/modules/render-runtime.js | Preserve preview host accessibility semantics when recreating the host node. |
| src/modules/editor-codemirror.js | Add optional contentAttributes support for CodeMirror content DOM. |
| src/index.html | Add ARIA semantics for status, panels (aria-labelledby), preview host region, and editor fallback textareas. |
| src/app.js | Pass ARIA attributes into CodeMirror initialization for editor accessibility. |
| playwright/helpers/app-test-helpers.ts | Centralize Playwright helper functions for app setup and common interactions. |
| playwright/layout-panels.spec.ts | New focused tests for layout/panels behavior using accessible locators. |
| playwright/rendering-modes.spec.ts | New focused tests for rendering/style modes and typecheck behavior. |
| playwright/diagnostics.spec.ts | New focused tests for diagnostics drawer and related editor navigation behavior. |
| playwright/github-pr-drawer.spec.ts | New focused tests for the Open PR drawer behavior and validation. |
| playwright/github-byot-ai.spec.ts | New focused tests for BYOT + AI chat/open PR feature-flagged UI flows. |
| playwright/app.spec.ts | Remove the previous monolithic spec in favor of modular specs/helpers. |
| AGENTS.md | Document Playwright selector guidance: prefer accessible locators, use locator() as fallback. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
Uh oh!
There was an error while loading. Please reload this page.