-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
31 lines (25 loc) · 880 Bytes
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
language: php
sudo: false
dist: trusty
php:
- 5.6
- 7.0
- 7.1
- hhvm
cache:
directories:
- vendor
before_install:
- export XDEBUG="/home/travis/.phpenv/versions/$(phpenv version-name)/etc/conf.d/xdebug.ini"
- is_hhvm () { [[ $TRAVIS_PHP_VERSION =~ ^hhvm ]]; }
- is_hhvm || mv -v "$XDEBUG" "$XDEBUG.disabled"
install:
- travis_retry composer update -a --no-interaction
- travis_retry wget https://scrutinizer-ci.com/ocular.phar
script:
- vendor/bin/phpcs --standard=PSR2 src tests
- vendor/bin/php-cs-fixer fix -v --dry-run --allow-risky=yes --using-cache=no
- if is_hhvm; then echo "xdebug.enable = On" >> /etc/hhvm/php.ini; else mv -v "$XDEBUG.disabled" "$XDEBUG"; fi
- vendor/bin/phpunit --coverage-clover=coverage.clover --coverage-text
after_script:
- is_hhvm || php ocular.phar code-coverage:upload --format=php-clover coverage.clover