language: php

php:
  - 7.1.18
  - 7.2
  - 7.3


addons:
  code_climate:
    repo_token: f250f6c653cfb19fe7460f186f46added2b5b57cf4b4255bbe63685dbff7d88e

services:
  - memcached
  - redis-server

jobs:
  include:
    - stage: "Tests"
      name: "Unit Tests"
      script: vendor/bin/phpunit -c . --coverage-clover build/logs/clover.xml
    - script: vendor/bin/phpstan analyse src/ --level 6 --no-progress
      name: "Static Analyser"

before_script:
  - if [[ "$TRAVIS_PHP_VERSION" != "hhvm" ]]; then echo "extension = memcached.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi
  - if [[ "$TRAVIS_PHP_VERSION" != "hhvm" ]]; then echo "extension = redis.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi
  - if [[ "$TRAVIS_PHP_VERSION" != "hhvm" ]]; then echo "extension = igbinary.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi
  - composer install

after_script:
  - vendor/bin/test-reporter
language: php

php:
  - 7.2
  - 7.3
  - 7.4

addons:
  code_climate:
    repo_token: f250f6c653cfb19fe7460f186f46added2b5b57cf4b4255bbe63685dbff7d88e

services:
  - memcached
  - redis-server

jobs:
  include:
    - stage: "Tests"
      name: "Unit Tests"
      script: vendor/bin/phpunit -c . --coverage-clover build/logs/clover.xml
    - script: vendor/bin/phpstan analyse src/ --level 6 --no-progress
      name: "Static Analyser"

before_script:
  - echo "extension = memcached.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
  - echo "extension = redis.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
  - echo "extension = igbinary.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
  - composer install

after_script:
  - vendor/bin/test-reporter

Remove hhvm and php7.1 as it’s out of support
Remove hhvm and php7.1 as it’s out of support

Signed-off-by: Lasse Mammen <79d569441e83fefae21c557952bd2e51effd5160@bookboon.com>
