-
The problemI am currently working on a react-native application and want to use Percy, a visual testing service to catch UI changes in my app. I don't go the storybook way. Currently, we use detox for testing, it generates screenshots artifacts which we directly upload to Percy. But the test comparison always fails right now because we don't have corresponding baseline snapshots for the base branch, develop. So, I want to be able to upload those baseline snapshots for the default branch manually and change them when I want. I need help with that. I have already checked the @percy/cli docs, I only see a way to upload manually but I don't see how to do it for the base branch. Here is the stack overflow question: https://stackoverflow.com/questions/72739336/how-to-manually-upload-baseline-screenshots-in-percy-for-base-branch Thanks Environment
DetailsIf necessary, describe the problem you have been experiencing in more detail. Debug logsIf you are reporting a bug, always include logs! Give the "Debugging SDKs" Please do not trim or edit these logs, often times there are hints in the full Code to reproduce issueGiven the nature of testing/environment bugs, it’s best to try and isolate the |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
👋🏼 hey @gilons! You can use
|
Beta Was this translation helpful? Give feedback.
👋🏼 hey @gilons! You can use
PERCY_BRANCH
to change the builds git branch and run a build to upload a set of screenshots you'd like to use for a baseline. https://docs.percy.io/docs/environment-variables#optional Something like:PERCY_BRANCH="your-baseline-branch-name-here" npx percy upload ./screenshots
(or whatever the CLI command you're running -- if it's the CLI thePERCY_BRANCH
env var will work)