#55668 closed defect (bug) (fixed)
skipOnAutomatedBranches() does not work as expected, take 2
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Milestone: | 6.0.1 | Priority: | normal |
| Severity: | normal | Version: | |
| Component: | Build/Test Tools | Keywords: | has-patch commit dev-reviewed |
| Focuses: | Cc: |
Description (last modified by )
Background: #39486, #49050, #50401, #54112.
As part of the changes in [51868] / #54112, the GITHUB_REF and GITHUB_EVENT_NAME environment variables added in [49267] are no longer passed to the Docker container, which breaks the skipOnAutomatedBranches() method and causes it to still run on branches other than trunk.
This was never noticed before, as most of these tests check the year in license.txt, the version in package.json, the year in bundled themes' readme.txt, etc. By the time WordPress 5.9 was released in January, all of these files were already updated.
Summary of the changes in the attached patch:
- Pass the
GITHUB_REFandGITHUB_EVENT_NAMEenvironment variables to the Docker container, so that they are available to PHPUnit. - Update the
'refs/heads/trunk' !== $github_refcondition to account for renaming themasterbranch totrunkin November 2021, following the decision made in June 2020. - Remove obsolete references to the
masterbranch in favor oftrunk. - Remove the redundant
'false' !== $github_event_namecondition. It appears to be copied in [49267] from'false' !== $travis_pull_requestadded in [47000]. Based on the list of events that trigger workflows, the event name can never be'false'as a string.
Attachments (1)
Change History (11)
#2
@
4 years ago
- Owner set to SergeyBiryukov
- Resolution set to fixed
- Status changed from new to closed
#3
@
4 years ago
- Keywords commit dev-feedback added
- Resolution fixed deleted
- Status changed from closed to reopened
Reopening for backporting to the 6.0 and 5.9 branches after a second committer's review.
In 53349: