Skip to content

Commit

Permalink
Update travis build
Browse files Browse the repository at this point in the history
  • Loading branch information
Riimu committed May 12, 2016
1 parent 63825dd commit 40f197d
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,29 @@ cache:
- vendor

before_install:
- if [[ $TRAVIS_PHP_VERSION =~ ^7 ]]; then phpenv config-rm xdebug.ini; fi
- composer self-update

install:
- composer require --no-update --no-interaction "phpunit/phpunit:*" "squizlabs/php_codesniffer:*" "fabpot/php-cs-fixer:*"
- travis_retry composer update --no-interaction --prefer-source
- travis_retry wget https://scrutinizer-ci.com/ocular.phar

before_script:
- if [[ $TRAVIS_PHP_VERSION =~ ^hhvm ]]; then echo 'xdebug.enable = On' >> /etc/hhvm/php.ini; fi

script:
- vendor/bin/phpunit --coverage-clover=coverage.clover
- >
if [[ $TRAVIS_PHP_VERSION =~ ^7 ]]; then
phpdbg -qrr vendor/phpunit/phpunit/phpunit --coverage-clover=coverage.clover --coverage-text;
else
vendor/bin/phpunit --coverage-clover=coverage.clover --coverage-text;
fi
- vendor/bin/phpcs --standard=PSR2 src tests
- vendor/bin/php-cs-fixer fix --dry-run --diff

after_script:
- if [ -f coverage.clover ]; then php ocular.phar code-coverage:upload --format=php-clover coverage.clover; fi
- >
if [[ ! $TRAVIS_PHP_VERSION =~ ^hhvm ]]; then
php ocular.phar code-coverage:upload --format=php-clover coverage.clover;
fi

0 comments on commit 40f197d

Please sign in to comment.