phpstan.yml 943 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. name: "PHPStan"
  2. on:
  3. - push
  4. - pull_request
  5. permissions:
  6. contents: read
  7. env:
  8. COMPOSER_ROOT_VERSION: dev-main
  9. jobs:
  10. tests:
  11. name: "PHPStan"
  12. runs-on: ubuntu-latest
  13. strategy:
  14. matrix:
  15. php-version:
  16. - "8.1"
  17. - latest
  18. steps:
  19. - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
  20. - uses: shivammathur/setup-php@44454db4f0199b8b9685a5d763dc37cbf79108e1 # 2.36.0
  21. with:
  22. php-version: "${{ matrix.php-version }}"
  23. coverage: none
  24. extensions: mongodb, redis, amqp
  25. - name: Add require for mongodb/mongodb to make tests runnable
  26. run: "composer require ${{ env.COMPOSER_FLAGS }} mongodb/mongodb --dev --no-update"
  27. - uses: ramsey/composer-install@3cf229dc2919194e9e36783941438d17239e8520 # 3.1.1
  28. with:
  29. dependency-versions: highest
  30. - name: Run PHPStan
  31. run: composer phpstan