Skip to main content

Create an App Percy project

Learn how to create an App Percy project.

App Percy is an all-in-one visual testing and review platform that allows you to run visual tests using either the BrowserStack SDK or the Percy SDK. If you choose the BrowserStack SDK, you can integrate visual tests into your automated test scripts. Alternatively, using the Percy SDK enables you to create and manage visual tests directly on the Percy dashboard. Based on your SDK selection, refer to the appropriate section for detailed instructions on creating a project and executing your visual tests.

Create your test script based on the required framework and language. Check if your framework and language are supported using the BrowserStack SDK.

Update your BrowserStack config file

In the browserstack.yml file:

  1. Set percy: true.
  2. Set a projectName.
    • After you run a test, both an Automate project and a Percy project are created with this name.
    • If a Percy project with this name already exists, your screenshots are added to the same project.
    • If the name matches an App Percy project, visual tests do not run, and you see an error message in your terminal. Functional tests still run as expected.
  3. Set percyCaptureMode: auto for Auto mode, or set percyCaptureMode: manual for Manual mode:
    • There are other supported capture modes in the percyCaptureMode:auto parameter. The following table lists and describes all the acceptable modes.
App Percy screenshot capture mode Description
auto Automatically capture screenshots on common events such as screenshot, click, and sendKeys.
testcase Automatically capture screenshots at the end of each test case.
click Automatically capture screenshots on every click.
screenshot Automatically capture screenshots on every driver.screenshot call.
manual This gives you more control over the screenshots you want captured. When used, you have to add the AppPercySDK.screenshot(driver, name) method at required points in your test script.

Update your test script

Update your test script to capture screenshots using the BrowserStack Percy SDK in Auto and Manual modes.

  • Auto Mode:
    • Percy automatically capture screenshots on common events such as screenshot, click, and sendKeys.
    • To manually capture screenshots in addition to auto mode, import the BrowserStack Percy SDK and use the appropriate SDK screenshot method at required points in your test script to capture the desired screenshots for your language and framework. Check here screenshot method for specific language and framework.
  • Manual Mode:

Your script is ready to execute visual tests, and Percy is prepared to receive the build.

We highly recommend using our BrowserStack SDK for Percy integration.

Follow these steps to create a project in App Percy:

  1. Sign in to App Percy.
  2. Click Create new project. The “Create a new project” window appears. Percy - Create new Project

  3. Select App as the platform and name your project.
  4. Link a repository (optional): Add your repository’s source code integration if needed.
  5. Choose baseline management:
    • Git is recommended for developers involved in feature development.
    • Visual Git is recommended for QA / SDET involved in testing & test automation.
  6. Click Create Project. App Percy - Create Project

App Percy is ready to receive your first build.
App Percy - Waiting for first build

App Percy generates a unique PERCY_TOKEN for every created project. This token identifies the organization and project for uploading snapshots. The token starts with app_xxxxxxxx for App Percy projects.

We're sorry to hear that. Please share your feedback so we can do better

Contact our Support team for immediate help while we work on improving our docs.

We're continuously improving our docs. We'd love to know what you liked






Thank you for your valuable feedback

Is this page helping you?

Yes
No

We're sorry to hear that. Please share your feedback so we can do better

Contact our Support team for immediate help while we work on improving our docs.

We're continuously improving our docs. We'd love to know what you liked






Thank you for your valuable feedback!

Talk to an Expert
Download Copy