Repository navigation
Conversation
This was referenced Sep 13, 2026
desrosj
force-pushed
the
fix-actions-5.9/update-php-test-matrix
branch
from
September 14, 2026 01:23
df6a7a8 to
bfd27c3
Compare
desrosj
force-pushed
the
fix-actions-5.9/update-php-test-matrix
branch
2 times, most recently
from
September 21, 2026 16:50
6c57e76 to
cb95d72
Compare
Owner
Author
|
Not actually merged. GitHub auto-closed this as merged during a reorder of the 🤖 Generated with Claude Code |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What?
unit-test.yml'sunit-phpjob ran once, unconditionally, on whatever PHP version the pulledwordpress/wordpress:cliDocker images default to — this branch's.wp-env.jsonnever sets aphpVersion, and the job has nomatrix:block, noshivammathur/setup-phpstep, and no PHP-version selection of any kind. Adds a realstrategy.matrixtesting PHP5.6,7.0,7.4,8.0, and8.1(the lowest and highest supported minor of every major this branch supports), wiresWP_ENV_PHP_VERSION: ${{ matrix.php }}at the job level sowp-env's Docker Compose config generation actually picks awordpress:php${version}-tagged image per leg, and adds amultisite: [false, true]companion axis so the existing single-site/multisite unit test runs (previously two unconditional steps inside the same job, gated onif: success() || failure()) become independent matrix legs instead. Also removes thespatie/phpunit-watcherdev dependency before linting/testing on PHP versions below7.2, which it doesn't support.Why?
Without a pinned PHP version,
unit-phpcurrently floats to whatever PHP version Docker Hub'swordpress/wordpress:clilatest-family tags resolve to today. Testing a real matrix of this branch's actually-supported PHP versions gives accurate, deterministic PHP-version coverage instead of an unversioned float, and isolates any genuinely PHP-version-specific failure to the one leg it actually affects rather than hiding it behind (or wrongly blaming it on) whatever PHP happens to be current on the day the job runs.WP_ENV_PHP_VERSIONis read directly bypackages/env/lib/config/config.js(config.env.development.phpVersion/config.env.tests.phpVersion = process.env.WP_ENV_PHP_VERSION || ...), whichpackages/env/lib/build-docker-compose-config.jsthen uses to select thewordpress:php${version}/wordpress:cli-php${version}/wordpressdevelop/phpunit:*-php-${version}-fpmimage tags — this branch's own copy ofpackages/env(v4.1.3) already supports the variable, so no source change topackages/envitself is needed, only the workflow wiring.5.6is a notably old PHP release for a CI matrix; verified before adding it that Docker Hub still serves thewordpress:php5.6,wordpress:cli-php5.6, andwordpressdevelop/phpunit:5-php-5.6-fpmimages this branch'spackages/envwould request for that leg (all four other legs' images verified to exist too), so the infrastructure this fix depends on genuinely exists.8.1isn't one ofbuild-docker-compose-config.js's explicitly-mapped PHPUnit-image versions on this branch, so it falls through to that image'slatesttag, same as every other unmapped version — confirmed that tag also resolves.This branch's
unit-test.ymldoesn't have the separatetest-php(matrixed)/phpcs(unmatrixed) job split some sibling branches have —lint-php(wp-env run composer run-script lint) and both single-site/multisite PHPUnit runs stay inside the oneunit-phpjob, so no host-sideshivammathur/setup-phpstep orcomposer config platform.phpoverride is needed: composer/phpcs already run inside thewp-envDocker container, using whatever PHP that container has, whichWP_ENV_PHP_VERSIONnow correctly selects. Checkedcomposer.jsondirectly: it has no staticconfig.platform.phpoverride on this branch, so the Composer-resolution conflict already found and being fixed elsewhere in this project onwp/6.1doesn't apply here.Use of AI Tools
This PR was created by Claude Code under my supervision. All code should be treated as AI-produced and not yet reviewed by a human until this PR is marked Ready for Review.