Update CI matrix and actions #21
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 | |
| on: | |
| - push | |
| - pull_request | |
| jobs: | |
| phpstan: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup PHP, with composer and extensions | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: '8.0' | |
| - name: Install dependencies with Composer | |
| uses: ramsey/composer-install@v3 | |
| - name: Run phpstan | |
| run: vendor/bin/phpstan analyse --level=6 src/ | |
| tests: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| dependencies: | |
| - highest | |
| - lowest | |
| # PHP 7.3 and 7.4 are not built here: no laminas-diactoros release | |
| # that Composer 2.10+ accepts as a psr/http-factory-implementation | |
| # provider supports them, so the dev dependencies cannot even be | |
| # installed on those versions. | |
| php-versions: | |
| - '8.0' | |
| - '8.1' | |
| - '8.2' | |
| - '8.3' | |
| exclude: | |
| # Lowest bounds of the dev dependencies (Slim 3.0, Pimple 3.0, | |
| # vfsStream 1.6.8) were released before PHP 8.1 and fatal on load | |
| # there. That is a limitation of those old releases, not of this | |
| # library: every tested PHP version is covered by the highest jobs. | |
| - dependencies: lowest | |
| php-versions: '8.1' | |
| - dependencies: lowest | |
| php-versions: '8.2' | |
| - dependencies: lowest | |
| php-versions: '8.3' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup PHP, with composer and extensions | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: ${{ matrix.php-versions }} | |
| - name: Install dependencies with Composer | |
| uses: ramsey/composer-install@v3 | |
| with: | |
| dependency-versions: ${{ matrix.dependencies }} | |
| - name: Run unit tests | |
| run: vendor/bin/phpunit |