Skip to content

Commit

Permalink
By default test on PHP 8.4
Browse files Browse the repository at this point in the history
The default test environment and CI
runs test suite on PHP 8.4.

PHP 8.4 compatible Xdebug 3.4.0beta1 has
been released by the Xdebug team. It was
installed inside the to make coverage
collection possible. One stable version
is available, we can migrate to it instead.

Composer and PHPStan were updated to the
most recent stable releases to resolve
left-over PHP 8.4 deprecation notices
and fatal errors.
  • Loading branch information
gocom committed Nov 22, 2024
1 parent 7461852 commit 5764751
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.PHONY: all clean docker-build docker-images help lint lint-fix repl shell test test-static test-unit bump bump-dev process-reports

IMAGE ?= php_8_3
IMAGE ?= php_8_4
PHP = docker compose run --rm php

all: test
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"php": ">=5.3.0"
},
"require-dev": {
"phpstan/phpstan": "1.12.0",
"phpstan/phpstan": "1.12.11",
"phpunit/phpunit": "^9.5.20",
"squizlabs/php_codesniffer": "3.*",
"symfony/yaml": "^5.4.40",
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
php:
build: ./docker/image/${IMAGE:-php_8_3}
build: ./docker/image/${IMAGE:-php_8_4}
volumes:
- .:/app
- ${COMPOSER_HOME:-$HOME/.composer}:/tmp
Expand Down
8 changes: 6 additions & 2 deletions docker/image/php_8_4/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM php:8.4-rc-cli
FROM php:8.4-cli

RUN apt-get update && apt-get install -y \
bash \
Expand All @@ -7,6 +7,10 @@ RUN apt-get update && apt-get install -y \
zip \
wget

COPY --from=composer:2.7 /usr/bin/composer /usr/bin/composer
RUN pecl install xdebug-3.4.0beta1

RUN docker-php-ext-enable xdebug

COPY --from=composer:2.8 /usr/bin/composer /usr/bin/composer

WORKDIR /app

0 comments on commit 5764751

Please sign in to comment.