Closed markacianfrani closed 1 year ago
Latest commit: bad455831b23ab5e821ead921579602a55c078b4
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR
Name | Link |
---|---|
Latest commit | bad455831b23ab5e821ead921579602a55c078b4 |
Latest deploy log | https://app.netlify.com/sites/astro-stencil/deploys/63cef728f178ab0008d78411 |
Deploy Preview | https://deploy-preview-1026--astro-stencil.netlify.app |
Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site settings.
Name | Link |
---|---|
Latest commit | bad455831b23ab5e821ead921579602a55c078b4 |
Latest deploy log | https://app.netlify.com/sites/astro-preview/deploys/63cef728a46f4100088d072c |
Deploy Preview | https://deploy-preview-1026--astro-preview.netlify.app |
Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site settings.
Brief Description
Lots of file changes because I had to rename our snapshot files and regenerate them.
We want to have VRTs for light theme in addition to dark theme. Currently, our light theme tests require us to duplicate our dark theme tests:
this worked fine for simple basic tests, however, once we start adding more tests for things like hover and focus state, it will get out of hand quickly having to duplicate those as well.
this PR creates a new fixture that will automatically run all the of VRTs twice, one for dark, one for light, off one single test and reduces the above to:
General Notes
It works by using Playwright's Parameters. I've split our project into three: 1 for regular e2e, 1 for dark theme, 1 for light theme. The project config in playwright.config.ts is responsible for changing the
theme
parameter for each. The fixture is responsible for checking if the theme is light, and then appends thelight-theme
body class.Issues and Limitations
If we go beyond simple, basic test folder structure, we'll need to add another param for that.
Types of changes
Checklist