diff --git a/composer.json b/composer.json index aba213db28..86e6d05780 100644 --- a/composer.json +++ b/composer.json @@ -3,10 +3,16 @@ "description": "PHPUnit dependencies for the PHP shipped in roles/*/files/php/.", "type": "project", "license": "MIT", + "require": { + "php": ">=8.3" + }, "require-dev": { - "phpunit/phpunit": "^13.3" + "phpunit/phpunit": "^12.0" }, "config": { + "platform": { + "php": "8.3" + }, "sort-packages": true }, "scripts": { diff --git a/utils/install/php.py b/utils/install/php.py index f46a1df4b2..c7fdd71147 100644 --- a/utils/install/php.py +++ b/utils/install/php.py @@ -19,7 +19,7 @@ _PHPUNIT_EXTENSIONS = ("dom", "mbstring", "xmlwriter") def ensure_php_toolchain() -> None: """Install the PHP interpreter, Composer and the extensions PHPUnit needs. - ``phpunit/phpunit ^13`` declares ``_PHPUNIT_EXTENSIONS`` as platform + ``phpunit/phpunit`` declares ``_PHPUNIT_EXTENSIONS`` as platform requirements and Composer refuses to resolve the vendor tree without them, so they are part of the toolchain rather than of the suite consuming it. A distro ships them as packages separate from the interpreter, which is why