Learn how to configure CircleCI to run your Rainforest tests.


CircleCI is a hosted continuous integration (CI) server. Using the Rainforest CLI, it’s easy to configure CircleCI to run your Rainforest test suite after each deployment.

See our CI Sample repo on Github for a more thorough explanation of how you can incorporate Rainforest tests into your release process for Circle CI, Jenkins, and Travis.

If you have CircleCI set up already, check out our CircleCI orb to easily integrate Rainforest tests with your CI flow.

The Flow

Our project is configured to provide a continuous delivery flow by default.

Every time code is pushed to the “develop” branch, CircleCI:

  1. Runs the automated tests.
  2. Deploys the “develop” branch to a staging server.
  3. Runs the Rainforest tests using the Rainforest CLI on the staging server.
  4. Once the Rainforest tests are successful, pushes the “develop” branch to the “master” branch.
  5. The previous step triggers another CI build, which pushes the code to production.

Note: If any of the above steps fail, the entire build fails, preventing the deployment of broken code to your users.

Getting Started with CircleCI

For a complete picture, we encourage you to consult CircleCI’s Getting Started documentation.

The Config.yml File

The primary way to configure the CircleCI tool is through a file in your Git repository. You can see the sample configuration for our project here.

Notice that instead of entering the Rainforest API key in the config.yml file, we use a test datatest data - Placeholders that allow you to inject other values into your tests. Rainforest supports three types: dynamic, static, and built-in. placeholder. For security reasons, we don’t expose the key to any reader of that file, especially when the repository is public.

Configure the test data in your project’s settings. You can find your Rainforest API token by navigating to your Integration settings.

An API token example.

Create a RAINFOREST_TOKEN variable in CircleCI, and you’re done.

You can find more details on environment variables and Circle CI here.

Testing Your Setup

Test your setup by committing a change to your develop branch and pushing it to your Git repository. CircleCI detects the change and deploys your code. With a new continuous delivery flow and QA process to match, you can move faster while not breaking things.

Note: If you don’t see your API token, we recommend clicking the Rotate API Token button to receive a new token.

If you have any questions, reach out to us at [email protected] or via the chat bubble below.

Updated 23 days ago


Learn how to configure CircleCI to run your Rainforest tests.

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.