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

Impove testing and add php 7.2 support #66

Merged
merged 1 commit into from
Apr 25, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 32 additions & 30 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,59 +2,61 @@ sudo: false

language: php

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

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

env:
global:
- COMPOSER_ARGS="--no-interaction --prefer-source"
- LEGACY_DEPS="phpunit/phpunit"
- SITE_URL: https://zendframework.github.io/zend-eventmanager
- GH_USER_NAME: "Matthew Weier O'Phinney"
- GH_USER_EMAIL: [email protected]
- GH_REF: github.com/zendframework/zend-eventmanager.git
- secure: "q6mC+KhLKsPYD22R9RI7lLhQGF5dSQ0QttmaFSQf/wtIntruVIFoyWt8ObR3zFsZ4xxra8MZFV2AjbMM9vqB28aHZ1jV5kbCbhTfSbdv0GT4nwqIHh84Ui7gCykJBqyyboWf/ekOv87cbuTg3EbqJcgdBh6/oyRGIVVB3HQayJJTTUCz+TQ/M4mpvOE+61FGpu6WLv465R8aKRi0ZLjk6qMtAY616cnGlPBOoNopyQM2+VTGyLOFgwnCUae3l4MSc8zsWgA4FLwttsYOzoVXit1ZXcqAt+XCAxUMntT3esIKVdeNejqQ7ZhMdMJpbdXTgfOD9kPt4fbNrcyg12Zkl0F3lHUNMb22PWNXb7tZ3+E4pR8B+6GtKXLRleEl9sPUKhxZ0CgwQErqOE8Osnw+BeNjueosNzJvrpxdHLX1a1+1v4VZIcikK+btW6YS+YLjZJgd80LI/4vQByUehgfFRuJnmjkMp+p9NN+PphdYHcQLfe2VU+qif114cR2WAyaiJ47zXMu2+vqp9sR20M2CfKZXrihiSO+CdbhSmep3sWaCuLWZtpsMx7u3rKl1o5doGLmkYAc+OaCEw5mZ/nVxzkH2ldNNcCeV2+ENKj4zlKoVXy1MB0KTT2U2rJ4pO5WhYLORbgBNNKeuD8r5nl65Dhn3gaIPXvlica/jIqay+/U="
- COMPOSER_ARGS="--no-interaction --no-plugins"
- COVERAGE_DEPS="satooshi/php-coveralls"

matrix:
include:
- php: 5.6
env:
- TEST_COVERAGE=true
- DEPLOY_DOCS="$(if [[ $TRAVIS_BRANCH == 'master' && $TRAVIS_PULL_REQUEST == 'false' ]]; then echo -n 'true' ; else echo -n 'false' ; fi)"
- PATH="$HOME/.local/bin:$PATH"
- DEPS=lowest
- php: 5.6
env:
- DEPS=latest
- php: 7
env:
- CS_CHECK=true
- DEPS=lowest
- php: 7
env:
- DEPS=latest
- php: 7.1

notifications:
email: false
env:
- DEPS=lowest
- php: 7.1
env:
- DEPS=latest
- BENCHMARKS=true
- CS_CHECK=true
- TEST_COVERAGE=true
- php: 7.2
env:
- DEPS=lowest
- php: 7.2
env:
- DEPS=latest

before_install:
- if [[ $TEST_COVERAGE != 'true' ]]; then phpenv config-rm xdebug.ini || return 0 ; fi
- composer self-update
- if [[ $TEST_COVERAGE == 'true' ]]; then composer require --dev --no-update satooshi/php-coveralls ; fi

install:
- travis_retry composer install $COMPOSER_ARGS
- if [[ $TRAVIS_PHP_VERSION =~ ^5.6 ]]; then travis_retry composer update $COMPOSER_ARGS --with-dependencies $LEGACY_DEPS ; fi
- composer info -i
- travis_retry composer install $COMPOSER_ARGS --ignore-platform-reqs
- if [[ $LEGACY_DEPS != '' ]]; then travis_retry composer update --with-dependencies $COMPOSER_ARGS $LEGACY_DEPS ; fi
- if [[ $DEPS == 'lowest' ]]; then travis_retry composer update --prefer-lowest --prefer-stable $COMPOSER_ARGS ; fi
- if [[ $DEPS == 'latest' ]]; then travis_retry composer update $COMPOSER_ARGS ; fi
- stty cols 120 && composer show

script:
- if [[ $TEST_COVERAGE == 'true' ]]; then composer test-coverage ; else composer test ; fi
- if [[ $CS_CHECK == 'true' ]]; then composer cs-check ; fi
- if [[ $DEPLOY_DOCS == "true" && "$TRAVIS_TEST_RESULT" == "0" ]]; then wget -O theme-installer.sh "https://raw.githubusercontent.com/zendframework/zf-mkdoc-theme/master/theme-installer.sh" ; chmod 755 theme-installer.sh ; ./theme-installer.sh ; fi

after_success:
- if [[ $DEPLOY_DOCS == "true" ]]; then echo "Preparing to build and deploy documentation" ; ./zf-mkdoc-theme/deploy.sh ; echo "Completed deploying documentation" ; fi

after_script:
- if [[ $TEST_COVERAGE == 'true' ]]; then composer upload-coverage ; fi

notifications:
email: false
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"php": "^5.6 || ^7.0"
},
"require-dev": {
"phpunit/PHPUnit": "^6.0.7 || ^5.7.14",
"phpunit/phpunit": "^6.0.7 || ^5.7.14",
"athletic/athletic": "^0.1",
"zendframework/zend-stdlib": "^2.7.3 || ^3.0",
"container-interop/container-interop": "^1.1.0",
Expand Down