.travis.yml
dist: trusty
language: php
php:
- 5.5
- 5.6
- 7.0
- 7.1
- 7.2
- hhvm
sudo: false
cache:
directories:
- $HOME/.composer/cache
before_script:
- mkdir -p build/logs
- mkdir -p build/cov
- travis_retry composer install --no-interaction --prefer-dist
script:
- if [[ $TRAVIS_PHP_VERSION = '5.6' ]]; then vendor/bin/phpcs --standard=psr2 src/; fi
- if [[ $TRAVIS_PHP_VERSION = '5.6' ]]; then vendor/bin/phpmd src text codesize,controversial,design,naming,unusedcode; fi
- if [[ $TRAVIS_PHP_VERSION = '5.6' ]]; then vendor/bin/phpunit -v --coverage-clover ./build/logs/clover.xml; fi
after_success:
- bash <(curl -s https://codecov.io/bash)
- if [[ $TRAVIS_PHP_VERSION = '5.6' ]]; then php vendor/bin/test-reporter --coverage-report ./build/logs/clover.xml; fi