Skip to content

Commit

Permalink
chore: update github workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
lucacividini committed Jan 31, 2024
1 parent a4ccd38 commit c62787b
Showing 1 changed file with 17 additions and 12 deletions.
29 changes: 17 additions & 12 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ jobs:
runs-on: ubuntu-latest
name: PHPStan
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.2
- name: Checkout
uses: actions/checkout@v2
- name: composer install
Expand All @@ -18,26 +22,23 @@ jobs:
runs-on: ubuntu-latest
name: PHP-CS-Fixer
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.2
- name: Checkout
uses: actions/checkout@v2
- name: composer install
run: composer install
- name: CS Check
run: composer cs-check

tests:
name: PHP ${{ matrix.php }} / SF ^${{ matrix.symfony }}
runs-on: ubuntu-latest
strategy:
matrix:
name:
- 'PHP 8.0 tests (Symfony 5.4)'
- 'PHP 8.0 tests (Symfony 6.0)'
include:
- php: '8.0'
symfony: 5.4.*
- php: '8.0'
symfony: 6.0.*
name: ${{ matrix.name }}
php: ['8.2']
symfony: ['6.2.*', '6.3.*', '6.4.*', '7.0.*']
steps:
- name: Checkout
uses: actions/checkout@v2
Expand All @@ -50,8 +51,12 @@ jobs:
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
- run: |
- if: matrix.symfony == '5.4.*'
run: |
sed -ri 's/"symfony\/framework-bundle": "(.+)"/"symfony\/framework-bundle": "${{ matrix.symfony }}"/' composer.json;
sed -ri 's/"symfony\/yaml": "(.+)"/"symfony\/yaml": "${{ matrix.symfony }}"/' composer.json;
- if: matrix.symfony != '5.4.*'
run: |
sed -ri 's/"symfony\/(.+)": "(.+)"/"symfony\/\1": "${{ matrix.symfony }}"/' composer.json;
if: matrix.symfony
- run: composer update --no-interaction --no-progress --ansi
- run: composer phpunit

0 comments on commit c62787b

Please sign in to comment.