Merge pull request #134 from meQuilibrium/php-8.4-deprecation-fixes #152
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI Tests | |
| on: | |
| push: | |
| pull_request: | |
| jobs: | |
| run-tests: | |
| runs-on: ubuntu-24.04 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| php: [ "8.0", "8.1", "8.2", "8.3", "8.4" ] | |
| composer_flags: [ "", "--prefer-lowest" ] | |
| symfony_version: [ "^5.4", "^6.4" ] | |
| exclude: | |
| - php: "8.0" | |
| symfony_version: "^6.4" | |
| name: PHP ${{ matrix.php }} SF ${{ matrix.symfony_version }} ${{ matrix.composer_flags}} | |
| env: | |
| PHP: ${{ matrix.os }} | |
| COMPOSER_MEMORY_LIMIT: -1 | |
| COMPOSER_FLAGS: ${{ matrix.composer_flags }} | |
| SYMFONY_VERSION: ${{ matrix.symfony_version }} | |
| PHP_VERSION: ${{ matrix.php }} | |
| steps: | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: ${{ matrix.php }} | |
| extensions: redis | |
| ini-values: memory_limit=256M,post_max_size=256M | |
| - name: Checkout ratelimit bundle | |
| uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 2 | |
| - name: Install dependencies | |
| run: | | |
| composer self-update | |
| if [ "$SYMFONY_VERSION" != "" ]; then composer require "symfony/symfony:${SYMFONY_VERSION}" --no-update; fi; | |
| if [ "$SYMFONY_VERSION" = "^6.4" ]; then composer remove --dev "friendsofsymfony/oauth-server-bundle" --no-update; fi; | |
| COMPOSER_MEMORY_LIMIT=-1 composer update --prefer-dist --no-interaction $COMPOSER_FLAGS | |
| - name: Static analysis | |
| run: | | |
| ./vendor/bin/phpstan --memory-limit=-1 | |
| - name: Run tests | |
| run: | | |
| SYMFONY_DEPRECATIONS_HELPER=weak vendor/bin/simple-phpunit --coverage-text --coverage-clover=coverage.clover | |
| - name: Upload coverage | |
| if: ${{ matrix.php == '8.2' && github.repository == 'jaytaph/RateLimitBundle' }} | |
| uses: sudo-bot/action-scrutinizer@latest | |
| with: | |
| cli-args: "--format=php-clover coverage.clover" |