language: php

sudo: false

php: [5.6, 7.0, 7.1, 7.2, 7.3]

matrix:
  include:
    - php: 5.4
      dist: trusty
    - php: 5.5
      dist: trusty
    - php: 5.3
      dist: precise
    # Test against LTS versions
    - php: 7.2
      env: SYMFONY_VERSION='^2'
    - php: 7.2
      env: SYMFONY_VERSION='^3'
    # Test against dev versions of dependencies
    - php: 7.2
      env: DEPENDENCIES='dev' SYMFONY_PHPUNIT_VERSION='7.5' # Avoid using PHPUnit 8 until our testsuite is compatible

cache:
  directories:
    - $HOME/.composer/cache/files
    - $HOME/symfony-bridge/.phpunit

before_install:
  - if [ "$DEPENDENCIES" = "dev" ]; then composer config minimum-stability dev; fi;
  - sh -c 'if [ "$SYMFONY_VERSION" != "" ]; then composer require -n --no-update symfony/lts=$SYMFONY_VERSION; fi;'

install:
  - composer install -n
  - vendor/bin/simple-phpunit install

script: vendor/bin/simple-phpunit -v --coverage-clover=coverage.clover

after_script:
  - wget https://scrutinizer-ci.com/ocular.phar
  - php ocular.phar code-coverage:upload --format=php-clover coverage.clover

language: php

sudo: false

php: [5.6, 7.0, 7.1, 7.2, 7.3]

matrix:
  include:
    - php: 5.4
      dist: trusty
    - php: 5.5
      dist: trusty
    - php: 5.3
      dist: precise
    # Test against LTS versions
    - php: 7.2
      env: SYMFONY_VERSION='^2'
    - php: 7.2
      env: SYMFONY_VERSION='^3'
    # Test against dev versions of dependencies
    - php: 7.2
      env: DEPENDENCIES='dev'

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

before_install:
  - if [ "$DEPENDENCIES" = "dev" ]; then composer config minimum-stability dev; fi;
  - sh -c 'if [ "$SYMFONY_VERSION" != "" ]; then composer require -n --no-update symfony/lts=$SYMFONY_VERSION; fi;'

install:
  - composer install -n

script: vendor/bin/phpunit -v --coverage-clover=coverage.clover

after_script:
  - wget https://scrutinizer-ci.com/ocular.phar
  - php ocular.phar code-coverage:upload --format=php-clover coverage.clover

Change Travis to use phpunit from vendors
Change Travis to use phpunit from vendors

The driver-testsuite package now depends on phpunit to force installing
a version compatible with the driver testsuite.
