diff --git a/.travis.yml b/.travis.yml index 6330c43..abd0c64 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,40 +1,49 @@ language: php php: - 7.1 + - 7.2 + - 7.3 -matrix: - include: - - php: 7.0 - env: coverage=on +before_install: + # turn off XDebug + - phpenv config-rm xdebug.ini || return 0 - allow_failures: - - php: 7.0 - env: coverage=on +install: + - travis_retry composer install --no-progress --prefer-dist script: - - vendor/bin/tester tests -s -p php $coverageArgs - - php code-checker/src/code-checker.php + - vendor/bin/tester tests -s -p php after_failure: # Print *.actual content - for i in $(find tests -name \*.actual); do echo "--- $i"; cat $i; echo; echo; done -before_script: - # Install Nette Tester & Code Checker - - travis_retry composer install --no-interaction --prefer-dist - - travis_retry composer create-project nette/code-checker code-checker ~2.5 --no-interaction - - if [ "$coverage" ]; then coverageArgs="-p phpdbg --coverage ./coverage.xml --coverage-src ./src"; fi +jobs: + include: + - name: Nette Code Checker + install: + - travis_retry composer create-project nette/code-checker temp/code-checker ~2 --no-progress + script: + - php temp/code-checker/code-checker --strict-types + + + - stage: Code Coverage + script: + - vendor/bin/tester -p phpdbg tests -s --coverage ./coverage.xml --coverage-src ./src + after_script: + - wget https://github.com/satooshi/php-coveralls/releases/download/v1.0.1/coveralls.phar + - php coveralls.phar --verbose --config tests/.coveralls.yml + + + allow_failures: + - stage: Code Coverage -after_script: - # Report Code Coverage - - > - if [ "$coverage" ]; then - wget https://github.com/satooshi/php-coveralls/releases/download/v1.0.1/coveralls.phar - && php coveralls.phar --verbose --config tests/.coveralls.yml; - fi sudo: false cache: directories: - $HOME/.composer/cache + +notifications: + email: false