language: php

sudo: false

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

php:
  - 5.4
  - 5.5
  - 5.6
  - 7.0
  - 7.1
  - 7.2
  - hhvm

matrix:
  include:
    - php: 5.3
      dist: precise
    - php: 7.2
      env: SYMFONY_VERSION='^2'
    - php: 7.2
      env: SYMFONY_VERSION='^3'
    # Test against dev dependencies
    - php: 7.2
      env: DEPS=dev

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

install:
  - composer install --no-progress

script:
  - vendor/bin/phpspec run -f pretty
  - vendor/bin/behat -fprogress --strict
