Codeship is a hosted continuous integration (CI) server. Using the Rainforest CLI, it's very easy to configure CodeShip to run your Rainforest test suite after each deploy.
We built a sample project on Github to show how we integrate with various CI tools, including Code Ship.
Our project is configured to provide a continuous delivery flow by default. Here's how it works!
Every time code is pushed to the 'develop' branch, C will:
- Run the automated tests
- Install the rainforest-cli
- Deploy the 'develop' branch to a staging server
- Run the rainforest tests using the rainforest-cli against the staging server
If any of the above steps fail, the whole build fails, preventing the deployment of broken code to your users.
We'll cover some important items next, but for the full picture, we encourage you to check out the Codeship documentation.
You must use the CodeShip web interface to configure your build. The first step to get CodeShip to work with rainforest is to install the rainforest-cli in the setup part of the configuration.
You simply need to add the following line to the setup section.
brew install rainforestapp/public/rainforest-cli
We now need to tell CodeShip what is our Rainforest API token to trigger the Rainforest run.
To configure environment variables, you can do so in the project's settings. You can find your Rainforest API token in the Settings section in your Rainforest QA account. You can then create a RAINFOREST_TOKEN variable in CodeShip and you're done.
The next step is to configure your deployment process to your staging server. In our example, we're using Heroku, but please refer to the CodeShip documentation if you're using a different hosting provider.
You can test your setup by committing a change to your develop branch and pushing it to your git repository. CodeShip should pick up on the change and deploy your code.
This is how many of our customers are increasing their QA coverage and linking Rainforest into their continuous delivery flow.
If you have any questions, please feel free to reach out to us at [email protected] or through Intercom!
Updated 3 months ago