Add @wordpress/env devDep and wp-env script#365
Conversation
|
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 Core Committers: Use this line as a base for the props when committing in SVN: To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## trunk #365 +/- ##
=============================================
+ Coverage 32.16% 51.47% +19.30%
Complexity 4410 4410
=============================================
Files 298 298
Lines 39206 39424 +218
=============================================
+ Hits 12610 20292 +7682
+ Misses 26596 19132 -7464
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
To fix e2e tests in CI, and to make instructions from
AGENTS.mdwork out of the box.Previously,
@wordpress/envwas installed globally (npm i -g) by the e2e CI workflow. With the recent update to@wordpress/env(which included a major change to the.wp-env.jsonformat), this has started failing.To fix this, we can simply add
@wordpress/envas adevDependencytopackage.jsonand have it installed locally. This allows us to control the version of the package that's used.As an additional benefit, this makes local setup consistent with CI, and more reproducible. Previously, Claude Code was struggling to get the environment to start, as the commands in
AGENTS.mdrequired runningnpm run wp-env start, which wouldn't work: https://github.com/WordPress/secure-custom-fields/blob/b25cb5858a3d3ee2676e0815b431c2b92b059dc0/AGENTS.mdEventually, we can consider upgrading to
@wordpress/envv11.x and its new format, but that's for another PR.