Skip to content
This repository has been archived by the owner on Jan 29, 2020. It is now read-only.

Commit

Permalink
Updated Travis CI configuration
Browse files Browse the repository at this point in the history
- added PHP 7.1 and 7.2 support
- removed HHVM support
- removed documentation deployment
- removed IRC notifications
- updated install process with legacy dependencies
  • Loading branch information
michalbundyra committed Apr 27, 2018
1 parent d6c3871 commit a61e48f
Showing 1 changed file with 27 additions and 36 deletions.
63 changes: 27 additions & 36 deletions .travis.yml
Expand Up @@ -2,25 +2,14 @@ sudo: false

language: php

branches:
except:
- /^release-.*$/
- /^ghgfk-.*$/

cache:
directories:
- $HOME/.composer/cache
- $HOME/.local
- zf-mkdoc-theme

env:
global:
- COMPOSER_ARGS="--no-interaction --ignore-platform-reqs"
- SITE_URL=https://zendframework.github.io/zend-mvc-plugin-flashmessenger
- GH_USER_NAME="Matthew Weier O'Phinney"
- GH_USER_EMAIL=matthew@weierophinney.net
- GH_REF=github.com/zendframework/zend-mvc-plugin-flashmessenger.git
- secure: "c58UgXfy+F7YJkW4bZKI82qY6GvtfKOiqyyybSon4Vrg3Xg9ZEhUFHbt/Bzaay+BwwKKoXqZww8c6WYPI6L/cPwe73iI2exHIesHMDUnhg+UOwOeM8mlwCBywePBfV3BuMH6BqeO+byAt4LEdKe+RpGCPEJY2FGc8o2MDDBcwOK4/6ydLg76ycXnduIhi74CFraHuYoW250povd/gdqNR8QMurdDsbEwr9R44rqV8EJ6P2XB8rpUuXZaiGfDYw626mIHhjUwrS34b/OeWg1+FYVuDqH2yZiYrrvt/bXlB+VPgwn9YuyTytgtWNqXVDtu54oFnllfkwGJGlcp4ra7H9E1fTqXTeggAgzk40AR8MkSn8kXJNi9EzREphNskA+wVdE1fmGbyTa2Xw5rLHK4xuFA26r6yxca0lUapdhTDknzgBdGoy2Jwk9pSyHPSIAp8th/0z54B16A5j6YkZW+UVmoa3Bk8ncFmEP4qwcKkbLiDF17icNNxyqdw56Lb9Ih15ZiUC6ZG81vWvXxZwN8dXTtDvtKGYkNRwcPtZEJq6z/nzBS3iyblKTH6FlAZr7REg23ZT5Emgr0sTwNP12oZP2Fqng4NHhvBePxFe1FjoLer9Ho/9ci0cW8LzTXzIbP/ahT1VdE5419AHtsWQF5nFlH/IfkF8X64x5gPKHAebw="
- COMPOSER_ARGS="--no-interaction"
- COVERAGE_DEPS="php-coveralls/php-coveralls"

matrix:
include:
Expand All @@ -30,56 +19,58 @@ matrix:
- php: 5.6
env:
- DEPS=locked
- DEPLOY_DOCS="$(if [[ $TRAVIS_BRANCH == 'master' && $TRAVIS_PULL_REQUEST == 'false' ]]; then echo -n 'true' ; else echo -n 'false' ; fi)"
- PATH="$HOME/.local/bin:$PATH"
- LEGACY_DEPS="phpunit/phpunit"
- php: 5.6
env:
- DEPS=latest
- TEST_COVERAGE=true
- php: 7
env:
- DEPS=lowest
- php: 7
env:
- DEPS=locked
- CHECK_CS=true
- LEGACY_DEPS="phpunit/phpunit"
- php: 7
env:
- DEPS=latest
- php: hhvm
- php: 7.1
env:
- DEPS=lowest
- php: hhvm
- php: 7.1
env:
- DEPS=locked
- php: hhvm
- CS_CHECK=true
- TEST_COVERAGE=true
- php: 7.1
env:
- DEPS=latest
- php: 7.2
env:
- DEPS=lowest
- php: 7.2
env:
- DEPS=locked
- php: 7.2
env:
- DEPS=latest
allow_failures:
- php: hhvm

notifications:
irc: "irc.freenode.org#zftalk.dev"
email: false

before_install:
- travis_retry composer self-update
- if [[ $TRAVIS_PHP_VERSION != "hhvm" && $TEST_COVERAGE != 'true' ]]; then phpenv config-rm xdebug.ini ; fi
- if [[ $TEST_COVERAGE != 'true' ]]; then phpenv config-rm xdebug.ini || return 0 ; fi

install:
- travis_retry composer install $COMPOSER_ARGS --ignore-platform-reqs
- if [[ $LEGACY_DEPS != '' ]]; then travis_retry composer update $COMPOSER_ARGS --with-dependencies $LEGACY_DEPS ; fi
- if [[ $DEPS == 'latest' ]]; then travis_retry composer update $COMPOSER_ARGS ; fi
- if [[ $DEPS == 'lowest' ]]; then travis_retry composer update --prefer-lowest --prefer-stable $COMPOSER_ARGS ; fi
- if [[ $TEST_COVERAGE == 'true' ]]; then travis_retry composer require --dev $COMPOSER_ARGS satooshi/php-coveralls:^1.0 ; fi
- travis_retry composer install $COMPOSER_ARGS
- composer show --installed
- if [[ $TEST_COVERAGE == 'true' ]]; then travis_retry composer require --dev $COMPOSER_ARGS $COVERAGE_DEPS ; fi
- stty cols 120 && composer show

script:
- if [[ $TEST_COVERAGE == 'true' ]]; then composer test-coverage ; else composer test ; fi
- if [[ $CHECK_CS == 'true' ]]; then composer cs-check ; fi
- if [[ $DEPLOY_DOCS == "true" && "$TRAVIS_TEST_RESULT" == "0" ]]; then travis_retry curl -sSL https://raw.githubusercontent.com/zendframework/zf-mkdoc-theme/master/theme-installer.sh | bash ; fi
- if [[ $CS_CHECK == 'true' ]]; then composer cs-check ; fi

after_script:
- if [[ $TEST_COVERAGE == 'true' ]]; then travis_retry composer upload-coverage ; fi
- if [[ $TEST_COVERAGE == 'true' ]]; then travis_retry php vendor/bin/php-coveralls -v ; fi

after_success:
- if [[ $DEPLOY_DOCS == "true" ]]; then ./zf-mkdoc-theme/deploy.sh ; fi
notifications:
email: false

0 comments on commit a61e48f

Please sign in to comment.