Allow symfony/http-client v7 and update php cs fixer (#34) #67
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: test | |
on: [push] | |
jobs: | |
php-cs-fixer: | |
name: PHP CS Fixer | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
php-version: [ 8.0, 8.1, 8.2 ] | |
composer-strategy: [ lowest, stable ] | |
steps: | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-version }} | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Cache composer dependencies | |
id: composer-cache | |
uses: actions/cache@v3 | |
with: | |
path: vendor | |
key: ${{ runner.os }}-php-${{ matrix.php-version }}-strategy-${{ matrix.composer-strategy }} | |
restore-keys: | | |
${{ runner.os }}-php-${{ matrix.php-version }}-strategy-${{ matrix.composer-strategy }} | |
- name: Install dependencies | |
run: 'composer update -W --prefer-${{ matrix.composer-strategy }} --no-ansi --no-interaction --no-progress --optimize-autoloader' | |
- name: Run PHP CS fixer | |
run: './vendor/bin/php-cs-fixer check --config=.php-cs-fixer.php' | |
phpstan: | |
name: PHPstan | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
php-version: [ 8.0, 8.1, 8.2 ] | |
composer-strategy: [ lowest, stable ] | |
steps: | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-version }} | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Cache composer dependencies | |
id: composer-cache | |
uses: actions/cache@v3 | |
with: | |
path: vendor | |
key: ${{ runner.os }}-php-${{ matrix.php-version }}-strategy-${{ matrix.composer-strategy }} | |
restore-keys: | | |
${{ runner.os }}-php-${{ matrix.php-version }}-strategy-${{ matrix.composer-strategy }} | |
- name: Install dependencies | |
run: 'composer update -W --prefer-${{ matrix.composer-strategy }} --no-ansi --no-interaction --no-progress --optimize-autoloader' | |
- name: Run PHPstan | |
run: './vendor/bin/phpstan analyse src --level=max' | |
phpspec: | |
name: PHPspec | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
php-version: [ 8.0, 8.1, 8.2 ] | |
composer-strategy: [ lowest, stable ] | |
steps: | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-version }} | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Cache composer dependencies | |
id: composer-cache | |
uses: actions/cache@v3 | |
with: | |
path: vendor | |
key: ${{ runner.os }}-php-${{ matrix.php-version }}-strategy-${{ matrix.composer-strategy }} | |
restore-keys: | | |
${{ runner.os }}-php-${{ matrix.php-version }}-strategy-${{ matrix.composer-strategy }} | |
- name: Install dependencies | |
run: 'composer update -W --prefer-${{ matrix.composer-strategy }} --no-ansi --no-interaction --no-progress --optimize-autoloader' | |
- name: Run PHPspec | |
run: './vendor/bin/phpspec run --config phpspec_coverage.yml' |