Skip to content

Repair wp/5.5 branch Actions: Add a PHP version test matrix - #85002

Open
desrosj wants to merge 1 commit into
fix-actions-5.5/fix-puppeteer-alias-lockfile-driftfrom
fix-actions-5.5/update-php-test-matrix
Open

desrosj wants to merge 1 commit into
fix-actions-5.5/fix-puppeteer-alias-lockfile-driftfrom
fix-actions-5.5/update-php-test-matrix

Conversation

@desrosj

@desrosj desrosj commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

Part of #82938.

What?

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

  • LOCAL_PHP is set to <version>-fpm from the matrix, so wp-env's phpunit container uses the wordpressdevelop/phpunit:<version>-fpm image.
  • The single npm run test-php && npm run test-unit-php-multisite step is split into a single site step and a multisite step, each running in its own leg.

Why?

The job ran PHPUnit once, in the wordpressdevelop/phpunit:latest image, so it never tested the PHP versions WordPress 5.5 supports. The matrix tests the lowest and highest supported minor version of each major PHP version WordPress 5.5 supports: 5.6 for PHP 5, and 7.0 and 7.4 for PHP 7. WordPress 5.5 doesn't support PHP 8.

How?

This branch's @wordpress/env (1.6.0) has no WP_ENV_PHP_VERSION support, and its wordpress and wordpress:cli images aren't versioned. Its phpunit service image is wordpressdevelop/phpunit:${LOCAL_PHP-latest}, and wp-env run passes the job's environment through to docker compose, so LOCAL_PHP selects the PHP version PHPUnit runs on. The WordPress containers still run on the floating wordpress images' PHP version.

test-php runs lint-php before the tests, so linting runs once per PHP version, on the single site leg. #85003 moves PHP coding standards checks into their own job.

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.

@desrosj desrosj added the [Type] Build Tooling Issues or PRs related to build tooling label Oct 16, 2026
@desrosj desrosj self-assigned this Oct 16, 2026
@coderabbitai

coderabbitai Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 00ffbaef-a3dc-4736-97ec-9bae39abe338

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

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 changed the title Repair wp/5.5 branch Actions: Add a PHP-version test matrix Repair wp/5.5 branch Actions: Add a PHP version test matrix Oct 19, 2026

@ramonjd ramonjd left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything red on this PR passes at the top of this stack (#85016).

Matrix matches the PHP compatibility table for this WordPress version: the lowest and highest supported minor of each PHP major.

This branch has not been deployed

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

Labels

[Type] Build Tooling Issues or PRs related to build tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants