Repository navigation
Repair wp/6.7 branch Actions: Ignore the stale Browserslist data warning in unit tests - #82901
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
|
Size Change: 0 B Total Size: 1.77 MB ℹ️ View Unchanged
|
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. Props Bot commandsYou can trigger Props Bot actions by commenting on this PR:
|
34de45c to
7e3c024
Compare
7e3c024 to
be0d8b5
Compare
be0d8b5 to
5370084
Compare
5370084 to
0776c03
Compare
0776c03 to
750bf04
Compare
750bf04 to
0bfa298
Compare
0bfa298 to
9ba7ff6
Compare
wp/6.7 branch Actions: Ignore stale Browserslist data warning in unit testswp/6.7 branch Actions: Ignore the stale Browserslist data warning in unit tests
9ba7ff6 to
9eb5a22
Compare
9eb5a22 to
5f51482
Compare
5f51482 to
1e05889
Compare
Part of #82783.
What?
This configures Jest to ignore the stale Browserslist data warning when running tests.
Why?
Browserslist's bundled
caniuse-litedatabase on this branch is old enough that it can print aconsole.warnthe first time it's consulted during a test run.@wordpress/jest-consoleautomatically fails any test where an unexpectedconsole.warnoccurs, so whichever suite happens to invoke Browserslist first would fail — even though none of them are actually testing anything related to Browserslist or console output.How?
This is the same fix as commit a468930, which was committed directly to the
wp/7.0branch and configuresBROWSERSLIST_IGNORE_OLD_DATAintest/unit/jest.config.js. It was applied by hand here rather than cherry-picked, becausewp/6.7'stest/unit/jest.config.jspredates theprocess.env.TZline the original commit anchors its change on.This was never merged forward to
wp/7.1ortrunkbecause those branches instead keepcaniuse-liteitself genuinely fresh via routine dependency-bump PRs (e.g. #79630), which isn't a viable long-term strategy for a frozen maintenance branch like this one.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.