Repository navigation
Conversation
…T-4410] - Why: plugin test workflows pin one WordPress version, so a regression in a new WordPress release reaches support before CI. The six TEC repo PRs for SOFT-4410 to SOFT-4415 each wired the same lookup in by hand. - What: a github-script action that lists the newest X.Y releases from the WordPress.org version check, each at its latest patch, as a JSON array for strategy.matrix. count picks how many (default 3); fewer offered fails. Unit tests, a live job in test.yml, README entries. - Impact: any plugin feeds the output into its matrix and passes each version to setup-slic's wp-version; new WordPress releases rotate in without editing a workflow.
This was referenced Dec 4, 2026
Closed
[SOFT-4411] Run PHP tests across the WordPress version matrix
the-events-calendar/event-tickets#4475
Closed
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.
Related
Part of SOFT-4410, under SOFT-4409. Also part of SOFT-4411, SOFT-4412, SOFT-4413, SOFT-4414 and SOFT-4415.
Summary
Adds
wp-test-matrix, an action that lists the newest WordPress X.Y releases, each at its latest patch, as a JSON array for a test workflow'sstrategy.matrix. With the defaultcountof 3 that is["7.1.5","7.0.9","6.9.12"]today. Each version goes to setup-slic's existingwp-versioninput, so the suites run once per release.Why
Plugin test workflows usually pin one WordPress version (
wp core update --force --version=6.8), so a break in a new WordPress release shows up in support before it shows up in CI. Testing against the latest few releases catches it first. The version lookup is the same for every plugin, so it lives here for any brand to use.Change
wp-test-matrix: asksapi.wordpress.org/core/version-check/1.7/, keeps the highest patch of each X.Y, skips betas and RCs, and returns the newestcountreleases. It runs on github-script like the other toolbox actions, so there's nothing to build.permissions: {}, since it needs no token.@v1, not@main.countexpression for workflows that only want the full matrix on some runs (for example, only on PRs intomain). The default is 3 on every run.test.ymlgets awp-test-matrixjob that runs the action against the real endpoint and fans a matrix out from its output, so a change in WordPress.org's answer fails here first.Using it
Testing
node --test: all tests pass, 14 of them new intests/actions/wp-test-matrix/. They cover the count input, duplicates, order,7.10above7.9, betas and RCs, retries, and failing when too few releases come back.test.ymluses: clean.["7.1.5","7.0.9","6.9.12"].wp-test-matrixjobs on this PR run it on a real runner and fan out one job per version.Summary by CodeRabbit