rector/.travis.yml

36 lines
1004 B
YAML

language: php
matrix:
include:
# run extra build with PHP 7.1
- php: 7.1
# add variables to enable coverage, coding standard check and static analysis
env: PHPUNIT_FLAGS="--coverage-clover coverage.xml"
install:
# install composer dependencies
- composer install
script:
# run tests
- vendor/bin/phpunit $PHPUNIT_FLAGS
# check coding standard (defined in composer.json "scripts" section)
# if this fails, run "composer fix-cs" to fix all fixable issues
# - composer check-cs
# check with phpstan (defined in composer.json "scripts" section)
- composer phpstan
after_script:
# upload coverage.xml file to Coveralls to analyze it
# minimal required coverage is set to 80+ %
- |
if [[ $PHPUNIT_FLAGS != "" ]]; then
wget https://github.com/satooshi/php-coveralls/releases/download/v1.0.1/coveralls.phar
php coveralls.phar --verbose
fi
# do not send success notifications, they have no value
notifications:
email:
on_success: never