language: php

php:
    - 5.3.3
    - 5.3
    - 5.4
    - 5.5
    - 5.6
    - 7.0
    - hhvm

matrix:
    allow_failures:
        - php: 7.0
        - php: hhvm

before_script:
    - echo 'extension=mongo.so' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
    - composer install --prefer-dist

script: phpunit -c tests

language: php

php:
    - 5.3.3
    - 5.3
    - 5.4
    - 5.5
    - 5.6
    - 7.0
    - hhvm

matrix:
    allow_failures:
        - php: 7.0
        - php: hhvm

before_script:
    # The mongo extension is not yet available on PHP 7
    - if [[ "$TRAVIS_PHP_VERSION" != "7.0" ]] && [[ "$TRAVIS_PHP_VERSION" != "hhvm" ]]; then echo 'extension=mongo.so' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi
    - if [[ "$TRAVIS_PHP_VERSION" = "7.0" ]] || [[ "$TRAVIS_PHP_VERSION" = "hhvm" ]]; then composer remove --dev --no-update doctrine/mongodb-odm; fi
    - composer install --prefer-dist

script: phpunit -c tests

Fix the composer install for PHP 7 and HHVM
Fix the composer install for PHP 7 and HHVM

The mongo extension is not available for these versions, so the ODM cannot be installed