ci.yml 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. name: CI
  2. on:
  3. push:
  4. pull_request:
  5. jobs:
  6. PHPUnit:
  7. name: PHPUnit (PHP ${{ matrix.php }})
  8. runs-on: ubuntu-22.04
  9. strategy:
  10. matrix:
  11. php:
  12. - 8.3
  13. - 8.2
  14. - 8.1
  15. - 8.0
  16. - 7.4
  17. - 7.3
  18. - 7.2
  19. - 7.1
  20. steps:
  21. - uses: actions/checkout@v4
  22. - uses: shivammathur/setup-php@v2
  23. with:
  24. php-version: ${{ matrix.php }}
  25. coverage: xdebug
  26. ini-file: development
  27. - run: composer install
  28. - run: vendor/bin/phpunit --coverage-text
  29. if: ${{ matrix.php >= 7.3 }}
  30. - run: vendor/bin/phpunit --coverage-text -c phpunit.xml.legacy
  31. if: ${{ matrix.php < 7.3 }}
  32. PHPStan:
  33. name: PHPStan (PHP ${{ matrix.php }})
  34. runs-on: ubuntu-22.04
  35. strategy:
  36. matrix:
  37. php:
  38. - 8.3
  39. - 8.2
  40. - 8.1
  41. - 8.0
  42. - 7.4
  43. - 7.3
  44. - 7.2
  45. steps:
  46. - uses: actions/checkout@v4
  47. - uses: shivammathur/setup-php@v2
  48. with:
  49. php-version: ${{ matrix.php }}
  50. coverage: none
  51. - run: composer install
  52. - run: vendor/bin/phpstan