Shippable Continuous Integration with PHP — Laravel 5.2
Shippable is a Continuous Integration/Deployment Platform, It supports almost every popular programming language (node, java, php, python, ruby etc), source code providers (github, bitbucket, gitlab), unit-test frameworks and notification services (slack, hipchat, irc).
Laravel is a famous open-source PHP framework for web applications with vast community support , cutting edge tools like artisan, laravel queues and integration with most of the services.
Putting both things together -
Integrating Laravel application with shippable CI platform is quite easy, you can get it up and running withing couple of minutes. For it you need to have shippable.yml file in root directory of your project, and your project must be in some source code providers like github, gitlab or bitbucket.
Lets get started with creating shippable.yml file -
Create shippable.yml file -
This file will be used by shippable to configure environment and getting your unit test cases running. Shippable.yml file is using .env.testing file to l copy it to .env file so that laravel can pickup environment variables.
Create .testing.env file -
Running builds -
Now sign-in to shippable.com using your sources code provider (if you have other than github or bitbucket then you can add that after sign-in (setting -> integration) , Go to enable project and enable your this laravel project (which is having shippable.yml file), Within a minute you will see your build running with unit-test reports & code coverage reports.
Test Report —
Code Coverage Report —
Sample project on github -