Skip to content

chore(dev): run phpstan with 8.4 #1615

chore(dev): run phpstan with 8.4

chore(dev): run phpstan with 8.4 #1615

Workflow file for this run

name: Tests
on:
pull_request:
push:
schedule:
# Run Monday morning at 3 o'clock
# ┌───────────── minute (0 - 59)
# │ ┌───────────── hour (0 - 23)
# │ │ ┌───────────── day of the month (1 - 31)
# │ │ │ ┌───────────── month (1 - 12)
# │ │ │ │ ┌───────────── day of the week (0 - 6)
# │ │ │ │ │
# │ │ │ │ │
# │ │ │ │ │
- cron: 0 3 * * 1
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
tests:
strategy:
fail-fast: false
matrix:
php: [8.1, 8.2, 8.3, 8.4]
laravel: [^10.0, ^11.0]
stability: [prefer-lowest, prefer-stable]
exclude:
- php: 8.1
laravel: ^11.0
name: P=${{ matrix.php }} L=${{ matrix.laravel }} ${{ matrix.stability }}
runs-on: ubuntu-latest
env:
COMPOSER_NO_INTERACTION: 1
steps:
- uses: actions/checkout@v4
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
ini-file: development
coverage: none
extensions: pdo_sqlite
# Due to version incompatibility with older Laravels we test, we remove it
- run: composer remove --dev larastan/larastan --no-update
- run: composer remove --dev friendsofphp/php-cs-fixer --no-update
- run: composer remove --dev phpstan/phpstan --no-update
- run: composer require illuminate/contracts:${{ matrix.laravel }} --no-update
- run: composer require illuminate/contracts:9.33 --no-update
if: matrix.laravel == '^9.0' && matrix.stability == 'prefer-lowest'
- 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: ${{ runner.os }}-${{ matrix.php }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: ${{ runner.os }}-${{ matrix.php }}-composer-
- run: composer update --prefer-dist --no-progress --${{ matrix.stability }}
- name: Run tests
run: composer tests