Skip to content

Commit

Permalink
Run testsuite on PHP 8.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ADmad committed May 7, 2022
1 parent d5735ff commit 0005ec8
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,24 @@ jobs:
strategy:
fail-fast: false
matrix:
php-version: ['7.2', '7.4', '8.0']
php-version: ['7.4', '8.0', '8.1']
composer-opts: ['']
include:
- php-version: '7.1'
composer-opts: '--prefer-lowest'

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
coverage: xdebug
coverage: pcov

- name: Composer install
run: |
if [[ ${{ matrix.php-version }} == '8.0' ]]; then
if [[ ${{ matrix.php-version }} == '8.0' || ${{ matrix.php-version }} == '8.1' ]]; then
composer remove --dev squizlabs/php_codesniffer phpstan/phpstan-shim phpunit/phpunit
composer require --dev phpunit/phpunit:^8.5
else
Expand All @@ -34,14 +34,14 @@ jobs:
- name: Run PHPUnit
run: |
if [[ ${{ matrix.php-version }} == '7.4' ]]; then
if [[ ${{ matrix.php-version }} == '8.0' ]]; then
vendor/bin/phpunit -v --debug --coverage-clover=coverage.clover
else
vendor/bin/phpunit --no-coverage
fi
- name: Code Coverage Report
if: matrix.php-version == '7.4'
if: matrix.php-version == '8.0'
run: |
wget https://scrutinizer-ci.com/ocular.phar
php ocular.phar code-coverage:upload --format=php-clover coverage.clover;
Expand All @@ -51,12 +51,12 @@ jobs:
runs-on: ubuntu-18.04

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '7.4'
php-version: '8.0'
coverage: none
tools: cs2pr

Expand All @@ -68,4 +68,4 @@ jobs:

- name: Run phpstan
if: success() || failure()
run: vendor/bin/phpstan.phar analyse src/ tests/ --no-progress --level 2
run: vendor/bin/phpstan.phar analyse src/ tests/ --no-progress --level 2

0 comments on commit 0005ec8

Please sign in to comment.