Merge pull request #55 from liip/php85 #166
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: | |
| branches: | |
| - '*.x' | |
| tags: | |
| - '[0-9].[0-9]+' | |
| pull_request: | |
| jobs: | |
| test: | |
| name: "PHPUnit" | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| php-version: ['7.4', '8.0', '8.1', '8.2', '8.3', '8.4', '8.5'] | |
| include: | |
| - php-version: '7.4' | |
| composer-flags: '--prefer-stable --prefer-lowest' | |
| steps: | |
| - name: Check out code into the workspace | |
| uses: actions/checkout@v3 | |
| - name: Setup PHP ${{ matrix.php-version }} | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: ${{ matrix.php-version }} | |
| - name: Remove dev tools to not interfere with dependencies | |
| run: composer remove --dev friendsofphp/php-cs-fixer phpstan/phpstan-phpunit phpstan/phpstan | |
| - name: Composer cache | |
| uses: actions/cache@v3 | |
| with: | |
| path: ${{ env.HOME }}/.composer/cache | |
| key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} | |
| - name: Install dependencies | |
| run: composer update ${{ matrix.composer-flags }} --prefer-dist --no-interaction | |
| - name: Run tests | |
| run: composer phpunit |