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 ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
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. Comment |
|
Size Change: 0 B Total Size: 1.73 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. You can also manually ask me to refresh this list by adding the 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. |
Part of #82784.
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 to 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 fails — even though none of them are actually testing anything related to Browserslist or console output.package-lock.jsonon this branch pinscaniuse-liteat1.0.30001636, published 2024-06-16 — well past the roughly six-month threshold Browserslist uses to decide the data is stale enough to warn about.How?
This is based on commit a468930, which was committed directly to the
wp/7.0branch and configuresBROWSERSLIST_IGNORE_OLD_DATAintest/unit/jest.config.js. It couldn't be cherry-picked cleanly here — that commit anchors its change immediately after aprocess.env.TZ = 'UTC';line that doesn't exist inwp/6.6's copy oftest/unit/jest.config.js— so the same two-line change was applied by hand instead.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.