Skip to content

Fix automated tests workflow #41

Fix automated tests workflow

Fix automated tests workflow #41

name: Automated Testing
on:
push:
jobs:
composer:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- php-version: '7.4'
lock-version: '3.4'
- php-version: '7.4'
lock-version: '4.4'
- php-version: '8.0'
lock-version: '5.0'
- php-version: '8.0'
lock-version: '5.4'
- php-version: '8.0'
lock-version: '6.0'
- php-version: '8.1'
lock-version: '6.4'
- php-version: '8.2'
lock-version: '7.0'
steps:
- uses: 'shivammathur/setup-php@v2'
with:
php-version: ${{ matrix.php-version }}
tools: composer
- uses: actions/checkout@v3
- name: Set versions
run: cp composer.${{ matrix.lock-version }}.lock composer.lock
- name: Install dependencies
uses: ramsey/composer-install@v2
- name: Validate composer.json and composer.lock
run: composer validate --strict
phpunit:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- php-version: '7.4'
lock-version: '3.4'
- php-version: '7.4'
lock-version: '4.4'
- php-version: '8.0'
lock-version: '5.0'
- php-version: '8.0'
lock-version: '5.4'
- php-version: '8.0'
lock-version: '6.0'
- php-version: '8.1'
lock-version: '6.4'
- php-version: '8.2'
lock-version: '7.0'
steps:
- uses: 'shivammathur/setup-php@v2'
with:
php-version: ${{ matrix.php-version }}
tools: composer
- uses: actions/checkout@v3
- name: Set versions
run: cp composer.${{ matrix.lock-version }}.lock composer.lock
- name: Install dependencies
uses: ramsey/composer-install@v2
- name: Run test suite
run: composer phpunit
php-cs-fixer:
runs-on: ubuntu-latest
steps:
- uses: 'shivammathur/setup-php@v2'
with:
php-version: 8.1
tools: composer
- uses: actions/checkout@v3
- name: Set versions
run: cp composer.6.4.lock composer.lock
- name: Install dependencies
uses: ramsey/composer-install@v2
- name: PHPStan analyse
run: composer cs-fixer-check
phpstan:
runs-on: ubuntu-latest
steps:
- uses: 'shivammathur/setup-php@v2'
with:
php-version: 8.1
tools: composer
- uses: actions/checkout@v3
- name: Set versions
run: cp composer.6.4.lock composer.lock
- name: Install dependencies
uses: ramsey/composer-install@v2
- name: WarmUp cache
run: php tests/console cache:warmup
- name: PHPStan analyse
run: composer phpstan