Update phpstan/phpstan requirement from 1.10.67 to 1.12.4 #299
Workflow file for this run
This file contains 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: Build | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build: | |
name: PHP ${{ matrix.php-versions }} ${{ matrix.composer-args }} | |
strategy: | |
fail-fast: false | |
matrix: | |
operating-system: [ubuntu-latest] | |
php-versions: ["8.0", "8.1", "8.2", "8.3"] | |
composer-args: ["", "--prefer-lowest"] | |
runs-on: ${{ matrix.operating-system }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup PHP | |
uses: shivammathur/setup-php@2.31.1 | |
with: | |
php-version: ${{ matrix.php-versions }} | |
extensions: mbstring | |
coverage: pcov | |
tools: cs2pr | |
- name: Setup problem matchers for PHPUnit | |
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json" | |
- name: Get composer cache directory | |
id: composer-cache | |
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
- name: Cache dependencies | |
uses: actions/cache@v4 | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: php${{ matrix.php-versions }}-composer-${{ matrix.composer-args }}-${{ hashFiles('**/composer.json') }} | |
restore-keys: php${{ matrix.php-versions }}-composer-${{ matrix.composer-args }}- | |
- name: Install Dependencies | |
run: | | |
composer update --no-progress --no-suggest --prefer-stable --optimize-autoloader ${{ matrix.composer-args }} | |
- name: PHPStan | |
run: composer phpstan | |
- name: Code Style Check | |
env: | |
PHP_CS_FIXER_IGNORE_ENV: true | |
run: composer style-check -- --format=checkstyle | cs2pr | |
- name: Test | |
run: composer test-with-coverage | |
- name: Upload Coverage | |
uses: codecov/codecov-action@v3 | |
with: | |
files: ./clover.xml | |
verbose: true |