From 43bc44cfd1a30ce2d14c43fa3cdbc86ff7fa5f52 Mon Sep 17 00:00:00 2001 From: Frank van Hest Date: Tue, 30 Dec 2025 15:04:48 +0100 Subject: [PATCH 1/6] Added support for PHP 8.4 and 8.5 --- composer.json | 2 +- docker-compose.yml | 16 +++++++++++++++- docker/php84/Dockerfile | 10 ++++++++++ docker/php84/conf.d/error_reporting.ini | 1 + docker/php84/conf.d/xdebug.ini | 6 ++++++ docker/php85/Dockerfile | 10 ++++++++++ docker/php85/conf.d/error_reporting.ini | 1 + docker/php85/conf.d/xdebug.ini | 6 ++++++ 8 files changed, 50 insertions(+), 2 deletions(-) create mode 100644 docker/php84/Dockerfile create mode 100644 docker/php84/conf.d/error_reporting.ini create mode 100644 docker/php84/conf.d/xdebug.ini create mode 100644 docker/php85/Dockerfile create mode 100644 docker/php85/conf.d/error_reporting.ini create mode 100644 docker/php85/conf.d/xdebug.ini diff --git a/composer.json b/composer.json index a568327..a70eecf 100644 --- a/composer.json +++ b/composer.json @@ -10,7 +10,7 @@ } ], "require": { - "php": "~8.2.0 || ~8.3.0" + "php": "~8.2.0 || ~8.3.0 || ~8.4.0 || ~8.5.0" }, "require-dev": { "beberlei/assert": "~v3.3", diff --git a/docker-compose.yml b/docker-compose.yml index 6b0e1b1..fd3456a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,4 +1,3 @@ -version: "3.7" services: php82: build: ./docker/php82/ @@ -6,9 +5,24 @@ services: - .:/var/www/html - ./docker/php82/conf.d/xdebug.ini:/usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini - ./docker/php82/conf.d/error_reporting.ini:/usr/local/etc/php/conf.d/error_reporting.ini + php83: build: ./docker/php83/ volumes: - .:/var/www/html - ./docker/php83/conf.d/xdebug.ini:/usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini - ./docker/php83/conf.d/error_reporting.ini:/usr/local/etc/php/conf.d/error_reporting.ini + + php84: + build: ./docker/php84/ + volumes: + - .:/var/www/html + - ./docker/php84/conf.d/xdebug.ini:/usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini + - ./docker/php84/conf.d/error_reporting.ini:/usr/local/etc/php/conf.d/error_reporting.ini + + php85: + build: ./docker/php85/ + volumes: + - .:/var/www/html + - ./docker/php85/conf.d/xdebug.ini:/usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini + - ./docker/php85/conf.d/error_reporting.ini:/usr/local/etc/php/conf.d/error_reporting.ini diff --git a/docker/php84/Dockerfile b/docker/php84/Dockerfile new file mode 100644 index 0000000..53fb494 --- /dev/null +++ b/docker/php84/Dockerfile @@ -0,0 +1,10 @@ +FROM php:8.4-cli + +RUN apt-get update && \ + apt-get install -y --no-install-recommends git libzip-dev zip unzip \ + && docker-php-ext-install zip + +RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer + +RUN pecl install xdebug \ + && docker-php-ext-enable xdebug diff --git a/docker/php84/conf.d/error_reporting.ini b/docker/php84/conf.d/error_reporting.ini new file mode 100644 index 0000000..7e566f4 --- /dev/null +++ b/docker/php84/conf.d/error_reporting.ini @@ -0,0 +1 @@ +error_reporting=E_ALL diff --git a/docker/php84/conf.d/xdebug.ini b/docker/php84/conf.d/xdebug.ini new file mode 100644 index 0000000..5a891b8 --- /dev/null +++ b/docker/php84/conf.d/xdebug.ini @@ -0,0 +1,6 @@ +zend_extension=xdebug + +[xdebug] +xdebug.mode=coverage +xdebug.client_host=host.docker.internal +xdebug.start_with_request=yes diff --git a/docker/php85/Dockerfile b/docker/php85/Dockerfile new file mode 100644 index 0000000..1467c3f --- /dev/null +++ b/docker/php85/Dockerfile @@ -0,0 +1,10 @@ +FROM php:8.5-cli + +RUN apt-get update && \ + apt-get install -y --no-install-recommends git libzip-dev zip unzip \ + && docker-php-ext-install zip + +RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer + +RUN pecl install xdebug \ + && docker-php-ext-enable xdebug diff --git a/docker/php85/conf.d/error_reporting.ini b/docker/php85/conf.d/error_reporting.ini new file mode 100644 index 0000000..7e566f4 --- /dev/null +++ b/docker/php85/conf.d/error_reporting.ini @@ -0,0 +1 @@ +error_reporting=E_ALL diff --git a/docker/php85/conf.d/xdebug.ini b/docker/php85/conf.d/xdebug.ini new file mode 100644 index 0000000..5a891b8 --- /dev/null +++ b/docker/php85/conf.d/xdebug.ini @@ -0,0 +1,6 @@ +zend_extension=xdebug + +[xdebug] +xdebug.mode=coverage +xdebug.client_host=host.docker.internal +xdebug.start_with_request=yes From 1cfa668d0d6a33e6ae9fe8d2f227bb2b424da636 Mon Sep 17 00:00:00 2001 From: Frank van Hest Date: Tue, 30 Dec 2025 15:19:58 +0100 Subject: [PATCH 2/6] Added PHP 8.4 and 8.5 to Github actions --- .github/workflows/tests.yml | 4 ++-- phpunit.xml.dist | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 174012c..f211575 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -11,7 +11,7 @@ jobs: strategy: fail-fast: true matrix: - php: [8.2, 8.3] + php: [8.2, 8.3, 8.4, 8.5] composer-flags: [ '' ] stability: ['prefer-stable'] experimental: [false] @@ -52,5 +52,5 @@ jobs: - name: Infection if: ${{ matrix.experimental == false }} - run: vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --only-covered --threads=4 --test-framework-options="--configuration=phpunit.xml.dist" --configuration=infection.json.dist + run: vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --only-covered --threads=4 --configuration=infection.json.dist diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 83ee3b2..5a8a829 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -2,7 +2,7 @@ - src + src src/ From ca162b534d53a4bb01bd8bfe8239972f17ae8a2d Mon Sep 17 00:00:00 2001 From: Frank van Hest Date: Tue, 30 Dec 2025 15:28:01 +0100 Subject: [PATCH 3/6] Try to prevent deprecation notices --- .github/workflows/tests.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f211575..8855d82 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -27,6 +27,10 @@ jobs: with: php-version: ${{ matrix.php }} coverage: xdebug + ini-values: | + error_reporting=E_ALL & ~E_DEPRECATED & ~E_USER_DEPRECATED + display_errors=On + - name: Get Composer Cache Directory id: composer-cache From 844070fc11546e69f5536589b9d19ad1e5507d50 Mon Sep 17 00:00:00 2001 From: Frank van Hest Date: Tue, 30 Dec 2025 15:45:43 +0100 Subject: [PATCH 4/6] Try to prevent deprecation notices --- .github/workflows/tests.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 8855d82..2ac72e8 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -27,10 +27,6 @@ jobs: with: php-version: ${{ matrix.php }} coverage: xdebug - ini-values: | - error_reporting=E_ALL & ~E_DEPRECATED & ~E_USER_DEPRECATED - display_errors=On - - name: Get Composer Cache Directory id: composer-cache @@ -56,5 +52,4 @@ jobs: - name: Infection if: ${{ matrix.experimental == false }} - run: vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --only-covered --threads=4 --configuration=infection.json.dist - + run: php -d error_reporting="E_ALL & ~E_DEPRECATED & ~E_USER_DEPRECATED" vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --only-covered --threads=4 --configuration=infection.json.dist From 141af2c9b3a1e98010daf47fb5ae09dd41924312 Mon Sep 17 00:00:00 2001 From: Frank van Hest Date: Tue, 30 Dec 2025 16:01:02 +0100 Subject: [PATCH 5/6] Try to prevent deprecation notices --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 2ac72e8..aed4390 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -52,4 +52,4 @@ jobs: - name: Infection if: ${{ matrix.experimental == false }} - run: php -d error_reporting="E_ALL & ~E_DEPRECATED & ~E_USER_DEPRECATED" vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --only-covered --threads=4 --configuration=infection.json.dist + run: php -d error_reporting="E_ALL & ~E_DEPRECATED" vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --only-covered --threads=4 --configuration=infection.json.dist From c4bde02a43e64b22bdd603a514978a486a4deb2f Mon Sep 17 00:00:00 2001 From: Frank van Hest Date: Tue, 30 Dec 2025 16:05:49 +0100 Subject: [PATCH 6/6] Try to prevent deprecation notices, now with a newer version of infection --- .github/workflows/tests.yml | 2 +- composer.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index aed4390..996060e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -52,4 +52,4 @@ jobs: - name: Infection if: ${{ matrix.experimental == false }} - run: php -d error_reporting="E_ALL & ~E_DEPRECATED" vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --only-covered --threads=4 --configuration=infection.json.dist + run: php -d error_reporting="E_ALL & ~E_DEPRECATED" vendor/bin/infection --min-msi=100 --min-covered-msi=100 --show-mutations --threads=4 --configuration=infection.json.dist diff --git a/composer.json b/composer.json index a70eecf..5429cba 100644 --- a/composer.json +++ b/composer.json @@ -14,7 +14,7 @@ }, "require-dev": { "beberlei/assert": "~v3.3", - "infection/infection": "^0.27", + "infection/infection": "^0.32", "phpstan/phpstan": "^1.10", "phpunit/phpunit": "^10.5", "roave/security-advisories": "dev-latest"