Skip to content

Commit d0a11d3

Browse files
committed
Run tests on PHP 8.1 and 8.2
1 parent dea3219 commit d0a11d3

File tree

2 files changed

+40
-8
lines changed

2 files changed

+40
-8
lines changed

.github/workflows/ci.yml

Lines changed: 35 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,27 +6,55 @@ on:
66

77
jobs:
88
PHPUnit:
9-
runs-on: ${{ matrix.os }}
9+
name: PHPUnit (PHP ${{ matrix.php }})
10+
runs-on: ubuntu-22.04
1011
strategy:
1112
matrix:
12-
os:
13-
- ubuntu-20.04
14-
- windows-2019
1513
php:
14+
- 8.2
15+
- 8.1
1616
- 8.0
1717
- 7.4
1818
- 7.3
1919
- 7.2
2020
- 7.1
2121
- 7.0
2222
steps:
23-
- uses: actions/checkout@v2
24-
- name: Setup PHP
25-
uses: shivammathur/setup-php@v2
23+
- uses: actions/checkout@v3
24+
- uses: shivammathur/setup-php@v2
2625
with:
2726
php-version: ${{ matrix.php }}
2827
extensions: zlib
2928
coverage: xdebug
29+
ini-file: development
30+
- run: composer install
31+
- run: vendor/bin/phpunit --coverage-text
32+
if: ${{ matrix.php >= 7.3 }}
33+
- run: vendor/bin/phpunit --coverage-text -c phpunit.xml.legacy
34+
if: ${{ matrix.php < 7.3 }}
35+
36+
PHPUnit-Windows:
37+
name: PHPUnit (PHP ${{ matrix.php }} on Windows)
38+
runs-on: windows-2022
39+
strategy:
40+
matrix:
41+
php:
42+
- 8.2
43+
- 8.1
44+
- 8.0
45+
- 7.4
46+
- 7.3
47+
- 7.2
48+
- 7.1
49+
- 7.0
50+
steps:
51+
- uses: actions/checkout@v3
52+
- uses: shivammathur/setup-php@v2
53+
with:
54+
php-version: ${{ matrix.php }}
55+
extensions: zlib
56+
coverage: xdebug
57+
ini-file: development
3058
- run: composer install
3159
- run: vendor/bin/phpunit --coverage-text
3260
if: ${{ matrix.php >= 7.3 }}

phpunit.xml.dist

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@
44
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
55
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd"
66
bootstrap="vendor/autoload.php"
7+
cacheResult="false"
78
colors="true"
8-
cacheResult="false">
9+
convertDeprecationsToExceptions="true">
910
<testsuites>
1011
<testsuite name="zlib React Test Suite">
1112
<directory>./tests/</directory>
@@ -16,4 +17,7 @@
1617
<directory>./src/</directory>
1718
</include>
1819
</coverage>
20+
<php>
21+
<ini name="error_reporting" value="-1" />
22+
</php>
1923
</phpunit>

0 commit comments

Comments
 (0)