Skip to content

Commit a0002bb

Browse files
committed
Run tests on PHP 8.3 and update test suite
1 parent 5d4aa1a commit a0002bb

File tree

4 files changed

+37
-19
lines changed

4 files changed

+37
-19
lines changed

Diff for: .github/workflows/ci.yml

+18-11
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,13 @@ on:
66

77
jobs:
88
PHPUnit:
9-
runs-on: ubuntu-latest
9+
name: PHPUnit (PHP ${{ matrix.php }})
10+
runs-on: ubuntu-22.04
1011
strategy:
1112
matrix:
1213
php:
14+
- 8.3
15+
- 8.2
1316
- 8.1
1417
- 8.0
1518
- 7.4
@@ -22,11 +25,11 @@ jobs:
2225
- 5.4
2326
- 5.3
2427
steps:
25-
- uses: actions/checkout@v2
26-
- name: Setup PHP
27-
uses: shivammathur/setup-php@v2
28+
- uses: actions/checkout@v4
29+
- uses: shivammathur/setup-php@v2
2830
with:
2931
php-version: ${{ matrix.php }}
32+
coverage: xdebug
3033
- run: composer install
3134
- run: vendor/bin/phpunit --coverage-text
3235
if: ${{ matrix.php >= 7.3 }}
@@ -35,12 +38,16 @@ jobs:
3538

3639
PHPUnit-hhvm:
3740
name: PHPUnit (HHVM)
38-
runs-on: ubuntu-18.04
41+
runs-on: ubuntu-22.04
42+
continue-on-error: true
3943
steps:
40-
- uses: actions/checkout@v2
41-
- uses: azjezz/setup-hhvm@v1
44+
- uses: actions/checkout@v4
45+
- run: cp "$(which composer)" composer.phar && ./composer.phar self-update --2.2 # downgrade Composer for HHVM
46+
- name: Run hhvm composer.phar install
47+
uses: docker://hhvm/hhvm:3.30-lts-latest
4248
with:
43-
version: lts-3.30
44-
- run: composer self-update --2.2 # downgrade Composer for HHVM
45-
- run: hhvm $(which composer) install
46-
- run: hhvm vendor/bin/phpunit --coverage-text
49+
args: hhvm composer.phar install
50+
- name: Run hhvm vendor/bin/phpunit
51+
uses: docker://hhvm/hhvm:3.30-lts-latest
52+
with:
53+
args: hhvm vendor/bin/phpunit

Diff for: composer.json

+7-3
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,18 @@
1515
"react/stream": "^1.2"
1616
},
1717
"require-dev": {
18-
"phpunit/phpunit": "^9.3 || ^5.7 || ^4.8.35",
18+
"phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36",
1919
"react/child-process": "^0.6.3",
2020
"react/event-loop": "^1.2"
2121
},
2222
"autoload": {
23-
"psr-4": { "Clue\\React\\Csv\\": "src/" }
23+
"psr-4": {
24+
"Clue\\React\\Csv\\": "src/"
25+
}
2426
},
2527
"autoload-dev": {
26-
"psr-4": { "Clue\\Tests\\React\\Csv\\": "tests/" }
28+
"psr-4": {
29+
"Clue\\Tests\\React\\Csv\\": "tests/"
30+
}
2731
}
2832
}

Diff for: phpunit.xml.dist

+8-4
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22

3-
<!-- PHPUnit configuration file with new format for PHPUnit 9.3+ -->
4-
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5-
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd"
3+
<!-- PHPUnit configuration file with new format for PHPUnit 9.6+ -->
4+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5+
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.6/phpunit.xsd"
66
bootstrap="vendor/autoload.php"
7+
cacheResult="false"
78
colors="true"
8-
cacheResult="false">
9+
convertDeprecationsToExceptions="true">
910
<testsuites>
1011
<testsuite name="CSV 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>

Diff for: phpunit.xml.legacy

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22

3-
<!-- PHPUnit configuration file with old format for PHPUnit 9.2 or older -->
3+
<!-- PHPUnit configuration file with old format for legacy PHPUnit -->
44
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
55
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/4.8/phpunit.xsd"
66
bootstrap="vendor/autoload.php"
@@ -15,4 +15,7 @@
1515
<directory>./src/</directory>
1616
</whitelist>
1717
</filter>
18+
<php>
19+
<ini name="error_reporting" value="-1" />
20+
</php>
1821
</phpunit>

0 commit comments

Comments
 (0)