-
Notifications
You must be signed in to change notification settings - Fork 66
feat(visual-testing): add Playwright visual testing suite with R2 baselines (SD-1867) #1998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(visual-testing): add Playwright visual testing suite with R2 baselines (SD-1867) #1998
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0a4f10ba40
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| await fileInput.setInputFiles(filePath); | ||
| // Wait for document to load and render | ||
| await page.waitForFunction( | ||
| () => (window as any).superdoc !== undefined && (window as any).editor !== undefined, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait for the harness ready flag after file upload
loadDocument() waits for (window as any).editor !== undefined, but the new harness onReady callback in tests/visual/harness/main.ts only sets window.superdoc and window.superdocReady and never assigns window.editor; this makes the wait condition unsatisfiable and causes every rendering test that calls superdoc.loadDocument(...) (e.g. basic-layout.spec.ts) to hang until timeout in CI.
Useful? React with 👍 / 👎.
- Port all 21 remaining stories from devtools/visual-testing into new category-based folder structure (comments-tcs, formatting, lists, field-annotations, headers, search, importing, structured-content) - Add R2 corpus document download script (scripts/download-test-docs.ts) - Update harness to support toolbar, comments, and trackChanges config - Add fixture helpers: setDocumentMode, setTextSelection, clickOnLine, clickOnCommentedText, pressTimes - Update CI workflows to download test documents from R2 before running - Update test paths from e2e-tests/test-data to local test-data/ - Update README.md and CLAUDE.md with new categories and helpers
…aths Consolidate from two separate R2 buckets into a single superdoc-visual-testing bucket with documents/ and baselines/ prefixes. - Rewrite all R2 scripts to use unified bucket (4 env vars instead of 5) - Auto-discover documents from R2 (no hardcoded list) - Add docs:upload script for easy document uploads - Mirror test folder structure in R2 document paths - Add migration script for old bucket → new bucket - Update all 15 test file paths to match new structure - Simplify CI workflows with job-level env vars
- Remove @argos-ci/playwright (caused webkit page crashes) - Fix header test missing loadDocument call - Fix tracked-change test using fragile DOM selector - Guard setDocumentMode against null toolbar - Increase test timeout to 60s, add 1 retry in CI - Parallelize R2 downloads (20 concurrent) for docs and baselines
No description provided.