Skip to content

Repair wp/5.8 branch Actions: Add a PHP-version test matrix - #332

Closed
desrosj wants to merge 1 commit into
fix-actions-5.8/docker-compose-v2from
fix-actions-5.8/update-php-test-matrix
Closed

desrosj wants to merge 1 commit into
fix-actions-5.8/docker-compose-v2from
fix-actions-5.8/update-php-test-matrix

Conversation

@desrosj

@desrosj desrosj commented Sep 13, 2026 •

Copy link
Copy Markdown
Owner

What?

Runs the PHPUnit job in unit-test.yml across a PHP version matrix: 5.6, 7.0, 7.4 and 8.0, each as a single site and a multisite leg.

  • WP_ENV_PHP_VERSION is set from the matrix, so wp-env uses the matching wordpress:php<version> images.
  • The single site and multisite test steps, which both ran in the one job, now each run in their own leg.

Why?

.wp-env.json sets no phpVersion, so the job ran once, on whatever PHP version the floating wordpress images use, which this branch was never written for. The matrix tests the lowest and highest supported minor version of each major PHP version.

How?

This branch's packages/env already reads WP_ENV_PHP_VERSION, so only the workflow changes. Composer still installs dependencies inside wp-env's composer container, from the committed composer.lock. Related PRs in this stack:

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.

🤖 Generated with Claude Code

@desrosj desrosj self-assigned this Sep 13, 2026
@desrosj
desrosj added this pull request to stack #172 September 13, 2026 03:39
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from 4668f96 to 3f09223 Compare September 14, 2026 01:36
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from 3f09223 to 96da21c Compare September 15, 2026 19:18
@desrosj
desrosj removed this pull request from stack #172 September 21, 2026 17:03
@desrosj
desrosj changed the base branch from fix-actions-5.8/fix-react-native-screens-git-dependency to wp/5.8 September 21, 2026 17:03
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from 96da21c to f6284b2 Compare September 21, 2026 17:04
@desrosj
desrosj changed the base branch from wp/5.8 to fix-actions-5.8/fix-workflow-branch-filters September 21, 2026 17:05
@desrosj
desrosj added this pull request to stack #397 September 21, 2026 17:05
@desrosj
desrosj removed this pull request from stack #397 September 22, 2026 16:04
@desrosj
desrosj changed the base branch from fix-actions-5.8/fix-workflow-branch-filters to wp/5.8 September 22, 2026 16:05
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from f6284b2 to e520dcd Compare September 22, 2026 16:07
@desrosj
desrosj changed the base branch from wp/5.8 to fix-actions-5.8/pin-composer-image September 22, 2026 16:14
@desrosj
desrosj added this pull request to stack #464 September 22, 2026 16:14
@desrosj
desrosj removed this pull request from stack #464 September 22, 2026 21:20
@desrosj
desrosj changed the base branch from fix-actions-5.8/pin-composer-image to wp/5.8 September 22, 2026 21:21
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from e520dcd to 2396af3 Compare September 22, 2026 21:40
@desrosj
desrosj changed the base branch from wp/5.8 to fix-actions-5.8/pin-composer-image September 22, 2026 21:41
@desrosj
desrosj added this pull request to stack #484 September 22, 2026 21:41
@desrosj
desrosj removed this pull request from stack #484 September 23, 2026 01:33
@desrosj
desrosj changed the base branch from fix-actions-5.8/pin-composer-image to wp/5.8 September 23, 2026 01:33
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from 2396af3 to 2280071 Compare September 23, 2026 01:53
@desrosj
desrosj changed the base branch from wp/5.8 to fix-actions-5.8/pin-composer-image September 23, 2026 01:54
@desrosj
desrosj added this pull request to stack #491 September 23, 2026 01:54
@desrosj
desrosj removed this pull request from stack #491 September 23, 2026 21:20
@desrosj
desrosj changed the base branch from fix-actions-5.8/pin-composer-image to wp/5.8 September 23, 2026 21:22
@desrosj
desrosj changed the base branch from wp/5.8 to fix-actions-5.8/docker-compose-v2 September 28, 2026 19:15
@desrosj
desrosj added this pull request to stack #571 September 28, 2026 19:16
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from f8b3bc1 to dce8595 Compare October 5, 2026 20:47
@desrosj
desrosj removed this pull request from stack #571 October 5, 2026 20:48
@desrosj
desrosj added this pull request to stack #615 October 5, 2026 20:48
@desrosj
desrosj removed this pull request from stack #615 October 7, 2026 01:12
@desrosj
desrosj added this pull request to stack #647 October 7, 2026 01:12
@desrosj
desrosj removed this pull request from stack #647 October 7, 2026 18:05
@desrosj
desrosj changed the base branch from fix-actions-5.8/docker-compose-v2 to wp/5.8 October 7, 2026 18:06
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from dce8595 to bae6c9a Compare October 7, 2026 18:07
@desrosj
desrosj changed the base branch from wp/5.8 to fix-actions-5.8/docker-compose-v2 October 7, 2026 18:08
@desrosj
desrosj added this pull request to stack #671 October 7, 2026 18:09
`unit-test.yml`'s `unit-php` job ran a single, versionless PHPUnit pass,
so it only ever exercised whatever PHP version the pulled `wordpress`/
`wordpress:cli`/PHPUnit images happened to default to. `wp-env` already
reads `WP_ENV_PHP_VERSION` (`packages/env/lib/config/config.js`) and
uses it to select a specific PHP-tagged image for both the WordPress
containers and the `phpunit` container
(`packages/env/lib/build-docker-compose-config.js`), so this env var
is sufficient to drive real, isolated per-version test runs without
any other code change.

Adds a `strategy.matrix.php` covering `5.6`, `7.0`, `7.4`, and `8.0`
(the range Gutenberg has historically supported on this branch), sets
`WP_ENV_PHP_VERSION: ${{ matrix.php }}` at the job level, and adds a
`multisite` matrix dimension so the single-site and multisite test
runs become independent, isolated legs instead of two steps that
always ran back-to-back in the same job. `fail-fast` is disabled so a
failure on one PHP version doesn't cancel the runs still verifying the
others.
@desrosj
desrosj removed this pull request from stack #671 October 8, 2026 19:34
@desrosj
desrosj force-pushed the fix-actions-5.8/update-php-test-matrix branch from bae6c9a to 5dc0106 Compare October 8, 2026 19:34
@desrosj
desrosj added this pull request to stack #694 October 8, 2026 19:35
@desrosj
desrosj removed this pull request from stack #694 October 9, 2026 13:13
@desrosj
desrosj added this pull request to stack #702 October 9, 2026 13:14
@desrosj
desrosj removed this pull request from stack #702 October 9, 2026 13:34
@desrosj
desrosj added this pull request to stack #705 October 9, 2026 13:34
@desrosj
desrosj removed this pull request from stack #705 October 9, 2026 14:01
@desrosj
desrosj added this pull request to stack #708 October 9, 2026 14:02
@desrosj
desrosj removed this pull request from stack #708 October 9, 2026 14:13
@desrosj
desrosj added this pull request to stack #712 October 9, 2026 14:13
@desrosj
desrosj marked this pull request as ready for review October 9, 2026 17:31
@github-actions

github-actions Bot commented Oct 9, 2026

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: desrosj <desrosj@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@desrosj

desrosj commented Oct 9, 2026

Copy link
Copy Markdown
Owner Author

Moved to WordPress#84438.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant