language: php
sudo: false

php:
  - 5.6
  - 7.0
  - 7.1
env:
  - COMPOSER_FLAGS="--prefer-lowest"
  - COMPOSER_FLAGS=""

matrix:
  fast_finish: true
  include:
    - php: 7.1
      env: 
        - TEST_COVERAGE=true

cache:
  directories:
    - $HOME/.composer/cache/files

before_install:
  - if [ "$TRAVIS_PHP_VERSION" != "hhvm" ]; then phpenv config-rm xdebug.ini; fi;
  - composer self-update

install:
  - composer update --prefer-dist --no-interaction ${COMPOSER_FLAGS}

script:
  - if [[ $TEST_COVERAGE ]]; then phpdbg -qrr bin/phpunit --coverage-clover clover.xml; else bin/phpunit; fi;

after_success:
  - if [[ $TEST_COVERAGE ]]; then wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover ./clover.xml; fi

notifications:
  on_success: never
  on_failure: always

language: php
sudo: false

php:
  - 5.6
  - 7.0
  - 7.1
  - 7.2
  - 7.3
env:
  - COMPOSER_FLAGS="--prefer-lowest"
  - COMPOSER_FLAGS=""

matrix:
  fast_finish: true
  include:
    - php: 7.1
      env: 
        - TEST_COVERAGE=true

cache:
  directories:
    - $HOME/.composer/cache/files

before_install:
  - if [ "$TRAVIS_PHP_VERSION" != "hhvm" ]; then phpenv config-rm xdebug.ini; fi;
  - composer self-update

install:
  - composer update --prefer-dist --no-interaction ${COMPOSER_FLAGS}

script:
  - if [[ $TEST_COVERAGE ]]; then phpdbg -qrr bin/phpunit --coverage-clover clover.xml; else bin/phpunit; fi;

after_success:
  - if [[ $TEST_COVERAGE ]]; then wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover ./clover.xml; fi

notifications:
  on_success: never
  on_failure: always

Add PHP 7.2 & 7.3 to build matrix
Add PHP 7.2 & 7.3 to build matrix