language: php

matrix:
  include:
    - php: '5.5'
      env: PHP_VERSION_USED="5.5"
    - php: '5.6'
      env: PHP_VERSION_USED="5.6"
    - php: '7.0'
      env: PHP_VERSION_USED="7.0"
    - php: '7.1'
      env: PHP_VERSION_USED="7.1"
    - php: hhvm
      env: PHP_VERSION_USED="hhvm"

before_script:
  - wget https://phar.phpunit.de/phpunit.phar
  - chmod a+x phpunit.phar
  - chmod 777 ./tests/travis/setup_arangodb.sh
  - ./tests/travis/setup_arangodb.sh

script: 
  - if [[ "${PHP_VERSION_USED}" == "5.5" ]]; then phpunit --configuration ./tests/phpunit.xml; fi
  - if [[ "${PHP_VERSION_USED}" == "5.6" ]]; then phpunit --configuration ./tests/phpunit.xml; fi
  - if [[ "${PHP_VERSION_USED}" == "7.0" ]]; then (cd tests && ../phpunit.phar . --colors=auto --verbose --bootstrap=bootstrap.php); fi
  - if [[ "${PHP_VERSION_USED}" == "hhvm" ]]; then phpunit --configuration ./tests/phpunit.xml; fi

language: php

matrix:
  include:
    - php: '5.5'
      env: PHP_VERSION_USED="5.5"
    - php: '5.6'
      env: PHP_VERSION_USED="5.6"
    - php: '7.0'
      env: PHP_VERSION_USED="7.0"
    - php: '7.1'
      env: PHP_VERSION_USED="7.1"
    - php: hhvm
      env: PHP_VERSION_USED="hhvm"

before_script:
  - wget https://phar.phpunit.de/phpunit.phar
  - chmod a+x phpunit.phar
  - chmod 777 ./tests/travis/setup_arangodb.sh
  - ./tests/travis/setup_arangodb.sh

script: 
  - if [[ "${PHP_VERSION_USED}" == "5.5" ]]; then phpunit --configuration ./tests/phpunit.xml; fi
  - if [[ "${PHP_VERSION_USED}" == "5.6" ]]; then phpunit --configuration ./tests/phpunit.xml; fi
  - if [[ "${PHP_VERSION_USED}" == "7.0" ]]; then (cd tests && ../phpunit.phar . --colors=auto --verbose --bootstrap=bootstrap.php); fi
  - if [[ "${PHP_VERSION_USED}" == "7.1" ]]; then (cd tests && ../phpunit.phar . --colors=auto --verbose --bootstrap=bootstrap.php); fi
  - if [[ "${PHP_VERSION_USED}" == "hhvm" ]]; then phpunit --configuration ./tests/phpunit.xml; fi

Fix tests not running under PHP 7.1
Fix tests not running under PHP 7.1
