.travis.yml 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. language: php
  2. sudo: false
  3. matrix:
  4. include:
  5. - php: 5.4
  6. env: phpunit_exclude_groups=datetimeinterface dependencies=lowest
  7. - php: 5.5
  8. - php: 5.6
  9. - php: 7.0
  10. - php: 7.1
  11. - php: 7.1
  12. env: dependencies=lowest
  13. - php: 7.2
  14. env: dependencies=lowest
  15. cache:
  16. directories:
  17. - $HOME/.composer/cache
  18. services: mongodb
  19. before_install:
  20. - if [[ "$TRAVIS_PHP_VERSION" = 5.* ]]; then echo 'extension=mongo.so' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi
  21. - if [[ "$TRAVIS_PHP_VERSION" != 5.* ]]; then echo 'extension=mongodb.so' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi
  22. - if [[ "$TRAVIS_PHP_VERSION" != 5.* ]]; then cp composer7.json composer.json; fi
  23. install:
  24. - |
  25. if [[ "$dependencies" = "lowest" ]]; then
  26. composer update --prefer-lowest --prefer-stable -n
  27. else
  28. composer install --prefer-dist
  29. fi
  30. script:
  31. - |
  32. if [[ ! $phpunit_exclude_groups ]]; then
  33. bin/phpunit -c tests/
  34. else
  35. bin/phpunit -c tests/ --exclude-group $phpunit_exclude_groups
  36. fi
  37. notifications:
  38. email:
  39. - gediminas.morkevicius@gmail.com
  40. - developers@atlantic18.com