We’re excited to provide first-class Jenkins support.

As the leading open source CI service, Jenkins gives teams of all shapes and sizes support to build, deploy, and automate any project. In the past 15 years, Jenkins has paved the way for organizations to scale their test automation efforts by providing true continuous checks to fit any workflow.

Visual testing has also risen from the CI/CD movement, integrating with functional tests for complete software confidence. When running alongside code reviews, visual testing provides a workflow to review visual changes and see exactly how your UI looks before deploying.

How it works

There are several ways to integrate Percy into your web application, component library, end-to-end testing framework, or static site. Once you’ve installed Percy and added snapshots, you’re ready to configure CI to kick off visual reviews with each Jenkins build.

Although we previously had basic support for Jenkins, our new Jenkins integration doesn’t require any manual custom configuration. Now, with just a few steps, you can run visual reviews with every CI build when using Jenkins’ default branch source plugins.

Configuring environment variables

To connect a Percy project to Jenkins, all you need to do is configure your PERCY_TOKEN environment variable. Jenkins allows you to configure environment variables with the Build Env Propagator or EnvInject plugins.

Alternatively, you can export the variables as part of your build script:

export PERCY_TOKEN=<your token> npm install npm test

Read our documentation for more details.

Visual testing workflow with Jenkins

Percy runs alongside your Jenkins CI pipelines and will auto-detect the commit, branch, and pull request details that the GitHub Branch Source Plugin or the Bitbucket Branch Source Plugin provide.

Note: If you’re not using the GitHub Branch Source Plugin or Bitbucket Branch Source Plugin, please review our environment variables docs page, and configure the necessary environment variables to include.

Pulling in this metadata allows us to determine the most relevant baseline snapshots to compare new snapshots against, and helps to keep your visual reviews synchronized with your code reviews.

With visual reviews on each pull request, you’re notified when visual changes are detected without having to manually QA your UI yourself.

One click will take you to review exactly what’s changed so you can easily spot visual regressions, or approve intended updates with confidence. Visual testing is all about saving your team time and helping you deploy with complete confidence in the visual integrity of your UI.