Skip to content

Conversation

@amanmahajan7
Copy link
Collaborator

@amanmahajan7 amanmahajan7 commented Oct 23, 2025

https://vitest.dev/guide/browser/visual-regression-testing.html#visual-regression-testing

This PR sets up VRT. We can use Update Screenshots label to update screenshots when needed

@amanmahajan7 amanmahajan7 self-assigned this Oct 23, 2025

env:
AUTHOR_NAME: 'github-actions[bot]'
AUTHOR_EMAIL: '41898282+github-actions[bot]@users.noreply.github.com'
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/>
);

await expect(getGrid()).toMatchScreenshot('basic-grid');
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Co-authored-by: amanmahajan7
@amanmahajan7 amanmahajan7 marked this pull request as ready for review October 24, 2025 15:33
Co-authored-by: amanmahajan7
@amanmahajan7 amanmahajan7 reopened this Oct 24, 2025
git config --global user.email "${{ env.AUTHOR_EMAIL }}"
git add test/visual/__screenshots__/.
git diff-index --quiet HEAD || git commit -m "${{ env.COMMIT_MESSAGE }}"
git push --set-upstream origin ${{ github.head_ref }}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this work for forked repos?
Do we need --set-upstream?

Copy link
Collaborator Author

@amanmahajan7 amanmahajan7 Oct 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this work for forked repos?

Not sure. We can revisit if needed. Wdyt?

Do we need --set-upstream?

Not needed

Co-authored-by: amanmahajan7
Co-authored-by: amanmahajan7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants