# Source https://medium.com/@remi_collin/testing-laravel-packages-for-backward-compatibility-using-travis-cabc3210e120
language: php

php:
  - 7.3
  - 7.4

env:  
  - LARAVEL_VERSION=5.8.*
  - LARAVEL_VERSION=6.4.*
  - LARAVEL_VERSION=7.0.*
  - LARAVEL_VERSION=8.0.*

matrix:
  fast_finish: true

before_script:
  - travis_retry composer self-update
  - travis_retry composer install --prefer-source --no-interaction 
  - if [ "$LARAVEL_VERSION" != "" ]; then composer require --dev "laravel/laravel:${LARAVEL_VERSION}" --no-update; fi;  
  - composer update

script:
  - ./vendor/bin/phpunit
