rector/.travis.yml
2018-10-28 20:35:26 +01:00

50 lines
1.0 KiB
YAML

language: php
matrix:
include:
- php: 7.1
env: STATIC_ANALYSIS=true RUN_RECTOR=true
- php: 7.1
env: COMPOSER_FLAGS="--prefer-lowest"
- php: 7.2
env: COVERAGE=true
install:
- composer update $COMPOSER_FLAGS
before_script:
# disable xdebug
- if [[ $COVERAGE == "" ]]; then phpenv config-rm xdebug.ini; fi
script:
- vendor/bin/phpunit
- |
if [[ $STATIC_ANALYSIS == true ]]; then
composer check-cs
composer phpstan
fi
# Rector demo run
- |
if [[ $RUN_RECTOR == true ]]; then
bin/rector process src --level symfony40 --dry-run
bin/rector generate-rector-overview >> rector-overview.md
fi
after_script:
# Coverage
- |
if [[ $COVERAGE == true && $TRAVIS_BRANCH == "master" ]]; then
vendor/bin/phpunit --coverage-clover coverage.xml
wget https://github.com/php-coveralls/php-coveralls/releases/download/v2.1.0/php-coveralls.phar
php php-coveralls.phar --verbose
fi
cache:
directories:
- $HOME/.composer/cache
notifications:
email: false