Skip to content

Commit 2d4c76c

Browse files
committed
Test framework for PHP 8.1
1 parent 24e7726 commit 2d4c76c

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

.github/workflows/test-phpunit.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,15 @@ jobs:
4040
strategy:
4141
fail-fast: false
4242
matrix:
43-
php-versions: ['7.3', '7.4', '8.0']
43+
php-versions: ['7.3', '7.4', '8.0', '8.1']
4444
db-platforms: ['MySQLi', 'Postgre', 'SQLite3', 'SQLSRV']
4545
mysql-versions: ['5.7']
4646
include:
47-
- php-versions: 7.4
47+
- php-versions: '7.4'
4848
db-platforms: MySQLi
49-
mysql-versions: 8.0
49+
mysql-versions: '8.0'
50+
- php-versions: '8.1'
51+
composer-flag: '--ignore-platform-req=php'
5052

5153
services:
5254
mysql:
@@ -121,17 +123,18 @@ jobs:
121123

122124
- name: Install dependencies
123125
run: |
124-
composer update --ansi --no-interaction
125-
composer remove --ansi --dev --unused -W rector/rector phpstan/phpstan friendsofphp/php-cs-fixer nexusphp/cs-config
126+
composer update --ansi --no-interaction ${{ matrix.composer-flag }}
127+
composer remove --ansi --dev --unused -W ${{ matrix.composer-flag }} -- rector/rector phpstan/phpstan friendsofphp/php-cs-fixer nexusphp/cs-config
126128
php -r 'file_put_contents("vendor/laminas/laminas-zendframework-bridge/src/autoload.php", "");'
127129
env:
128130
COMPOSER_AUTH: ${{ secrets.COMPOSER_AUTH }}
129131

130-
- name: Profile slow tests in PHP 7.4 MySQLi for now
131-
if: matrix.php-versions == '7.4' && matrix.db-platforms == 'MySQLi'
132+
- name: Profile slow tests in PHP 8.0 MySQLi for now
133+
if: matrix.php-versions == '8.0' && matrix.db-platforms == 'MySQLi'
132134
run: echo "TACHYCARDIA_MONITOR_GA=enabled" >> $GITHUB_ENV
133135

134136
- name: Test with PHPUnit
137+
continue-on-error: ${{ matrix.php-versions == '8.1' }}
135138
run: script -e -c "vendor/bin/phpunit --color=always"
136139
env:
137140
DB: ${{ matrix.db-platforms }}

0 commit comments

Comments
 (0)