Skip to content

CI: Test PHP 7.2 to 8.4 #26

CI: Test PHP 7.2 to 8.4

CI: Test PHP 7.2 to 8.4 #26

Workflow file for this run

name: Testing
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
run:
runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ 'ubuntu-latest', 'windows-latest', 'macos-latest' ]
php-version: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ]
include:
- operating-system: ubuntu-latest
php-version: '7.2'
fail-fast: false
steps:
- uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
coverage: xdebug
- name: Validate composer.json and composer.lock
run: composer validate
- name: Install dependencies
run: composer update --prefer-dist --no-progress
- name: Check PHP syntax with PHP Parallel Lint
run: ./vendor/bin/parallel-lint src/ tests/
- name: Run Psalm static code analysis
run: ./vendor/bin/psalm
if: contains('7.2 7.3 7.4 8.0 8.1 8.2 8.3', matrix.php-version)
- name: Run PHPUnit test suite
run: ./vendor/bin/phpunit
- name: Check code coverage
run: ./vendor/bin/coverage-check clover.xml 100
if: contains('7.2 7.3 7.4', matrix.php-version)