language: php
dist: trusty
php:
    - 5.6
    - 7
    - 7.1
    - nightly
env:
    matrix:
        - COMPOSER_PREFER="--prefer-stable"
        - COMPOSER_PREFER="--prefer-lowest"
matrix:
    allow_failures:
        -
            php: nightly
    fast_finish: true
before_script:
    - >-
        echo 'always_populate_raw_post_data = -1' >> ~/.phpenv/versions/$(phpenv
        version-name)/etc/conf.d/travis.ini
    - |
        if [ ! $(php -m | grep -ci xdebug) -eq 0 ] ; then
            phpenv config-rm xdebug.ini
        fi
    - composer global require hirak/prestissimo
    - composer update $COMPOSER_PREFER
    - |
        # We force latest atoum on php >=7
        if [ $(php -r 'echo phpversion();' | sed -e 's/\..*//g') -eq 7 ] ; then
            composer update --prefer-stable atoum/atoum
        fi
    - 'php -S 127.0.0.1:8888 -t "$TRAVIS_BUILD_DIR/www" &> /dev/null &'
script:
    - vendor/bin/atoum -ulr
    - vendor/bin/behat -f progress

language: php
dist: trusty
cache:
    directories:
        - vendor
php:
    - 5.6
    - 7
    - 7.1
    - nightly
env:
    matrix:
        - COMPOSER_PREFER="--prefer-stable"
        - COMPOSER_PREFER="--prefer-lowest"
matrix:
    allow_failures:
        -
            php: nightly
    fast_finish: true
before_script:
    - >-
        echo 'always_populate_raw_post_data = -1' >> ~/.phpenv/versions/$(phpenv
        version-name)/etc/conf.d/travis.ini
    - |
        if [ ! $(php -m | grep -ci xdebug) -eq 0 ] ; then
            phpenv config-rm xdebug.ini
        fi
    - composer global require hirak/prestissimo
    - composer update $COMPOSER_PREFER
    - |
        # We force latest atoum on php >=7
        if [ $(php -r 'echo phpversion();' | sed -e 's/\..*//g') -eq 7 ] ; then
            composer update --prefer-stable atoum/atoum
        fi
    - 'php -S 127.0.0.1:8888 -t "$TRAVIS_BUILD_DIR/www" &> /dev/null &'
script:
    - vendor/bin/atoum -ulr
    - vendor/bin/behat -f progress

Add cache of vendor directory
Add cache of vendor directory
