Conversation
Bumps: - ts-jest 29.2.2 -> 29.4.9 - ts-loader 9.2.6 -> 9.5.7 - @playwright/test + playwright 1.51.1 -> 1.59.1 - @wordpress/jest-console 8.25.0 -> 8.44.0 - @wordpress/jest-preset-default 12.23.0 -> 12.44.0 - @wordpress/babel-preset-default 8.3.0 -> 8.44.0 - @wordpress/babel-plugin-makepot 4.3.2 -> 6.44.0 - @wordpress/browserslist-config 5.3.0 -> 6.44.0 None of these ship in the runtime bundle; impact limited to build/test/lint tooling. lint:js, test:js, and build:client all pass.
Bumps: - @testing-library/react 14.3.1 -> 16.3.2 - @testing-library/jest-dom 5.17.0 -> 6.9.1 - @types/testing-library__jest-dom 5.14.9 -> 6.0.0 - @testing-library/dom added as explicit peer at 10.4.1 @testing-library/user-event is intentionally held at 13.5.0 for now. The v14 migration causes widespread act() warnings and 5s test timeouts in components using @wordpress/components Popover/floating-ui, plus the `paste(el, data)` -> `paste(data)` API shift hits ~10 call sites. Will land as its own PR. lint:js clean, test:js and build:client pass.
Safe minor bumps of three @woocommerce leaf packages that don't pull in the @wordpress/i18n@6 chain. Deferred from Phase 3 to a follow-up PR (scope explosion): - @wordpress/{i18n,a11y,api-fetch,date,dom-ready,hooks,html-entities,url} to the 6.17/4.44 line — i18n@6 introduces stricter TransformedText<literal> generic typing that surfaces ~58 TS errors in sprintf/createInterpolateElement callsites, and the others are coupled via peer dependencies. - @woocommerce/navigation 8.2.0 — breaks documents/disputes/transactions/deposits filter tests; needs investigation. - @wordpress/base-styles 6.20.0 — uses CSS Media Queries Level 4 syntax ('@media not (prefers-reduced-motion)') which the project's sass version cannot parse. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Updates the project’s JS/TS toolchain and test dependencies to newer versions, and refreshes Jest snapshots to match the updated rendering/serialization output.
Changes:
- Bump key dev tooling packages (ts-jest, ts-loader, Playwright,
@wordpressjest/babel/browserslist packages) and TypeScript to 4.9.5. - Upgrade Testing Library packages (React, jest-dom) and add
@testing-library/domto satisfy new peer requirements. - Update affected Jest snapshots and add dev changelog entries documenting the dependency upgrade phases.
Reviewed changes
Copilot reviewed 13 out of 14 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| package.json | Updates dependency versions for tooling/testing/runtime packages. |
| includes/multi-currency/client/settings/single-currency/tests/snapshots/index.test.js.snap | Snapshot updates from dependency changes (Emotion/class/style serialization). |
| includes/multi-currency/client/settings/multi-currency/tests/snapshots/index.test.js.snap | Snapshot updates reflecting updated DOM serialization. |
| client/settings/payment-methods-list/tests/snapshots/activation-modal.test.js.snap | Snapshot updates reflecting updated DOM serialization. |
| client/settings/fraud-protection/protection-levels/protection-level-modal-notice/tests/snapshots/index.test.js.snap | Snapshot updates reflecting updated class naming/output. |
| client/settings/fraud-protection/advanced-settings/cards/tests/snapshots/purchase-price-threshold.test.js.snap | Snapshot updates reflecting updated Emotion output/class names. |
| client/settings/fraud-protection/advanced-settings/tests/snapshots/rule-toggle.test.js.snap | Snapshot updates reflecting updated DOM serialization. |
| client/settings/fraud-protection/advanced-settings/tests/snapshots/rule-card.test.js.snap | Snapshot updates reflecting updated DOM serialization. |
| client/settings/fraud-protection/advanced-settings/tests/snapshots/rule-card-notice.test.js.snap | Snapshot updates reflecting updated DOM serialization. |
| client/settings/fraud-protection/advanced-settings/tests/snapshots/index.test.js.snap | Snapshot updates reflecting updated Emotion output/class names. |
| client/settings/fraud-protection/advanced-settings/tests/snapshots/allow-countries-notice.test.js.snap | Snapshot updates reflecting updated DOM serialization. |
| changelog/dev-npm-upgrade-phases-1-3 | Adds a dev changelog entry describing staged npm upgrades. |
| changelog/dev-npm-audit-updates | Adds a dev changelog entry describing audit/minor bumps and TS update rationale. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
The package.json overrides block forced @woocommerce/components to use @woocommerce/currency@4.3.0, leaving two copies in the tree after Phase 3 bumped the root to 5.0.0. Aligning the override to 5.0.0 dedupes the tree. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Co-authored-by: Shruti Moorthy <shruti@MacBook-Pro-2.lan> Co-authored-by: Valery Sukhomlinov <683297+dmvrtx@users.noreply.github.com> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…0.1 (#11581) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Valery Sukhomlinov <683297+dmvrtx@users.noreply.github.com>
#11583) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Valery Sukhomlinov <683297+dmvrtx@users.noreply.github.com>
…#11582) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Valery Sukhomlinov <683297+dmvrtx@users.noreply.github.com>
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Valery Sukhomlinov <683297+dmvrtx@users.noreply.github.com>
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Valery Sukhomlinov <683297+dmvrtx@users.noreply.github.com>
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Valery Sukhomlinov <683297+dmvrtx@users.noreply.github.com>
Test the buildOption 1. Jetpack Beta
Option 2. Jurassic Ninja - available for logged-in A12s🚀 Launch a JN site with this branch 🚀 ℹ️ Install this Tampermonkey script to get more options. Build info:
Note: the build is updated when a new commit is pushed to this PR. |
|
Size Change: -4.01 kB (0%) Total Size: 959 kB
ℹ️ View Unchanged
|
The Phase 2 testing-library bumps allowed jsdom's nwsapi CSS selector
engine to upgrade from 2.2.12 to 2.2.23, which regressed handling of
attribute selectors containing '%' characters.
document.querySelector('label[for="size%f0%9f%98%86"]')
returns null in 2.2.23 even though the matching <label> exists. This
broke the wc-product-page compatibility test that simulates the
woo-variation-swatches plugin's percent-encoded variation IDs.
Pinning nwsapi to 2.2.12 via overrides restores the previous behavior
without affecting other dependencies.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
frosso
left a comment
There was a problem hiding this comment.
Most of the packages upgraded are test-related, and the rest of the dependencies are extracted (so we're deferring to the site's bundled dependencies). Tests are passing, so 👍
| @@ -0,0 +1,3 @@ | |||
| Significance: patch | |||
| Type: dev | |||
| Comment: Staged npm upgrades — Phase 1 (dev tooling: ts-jest, ts-loader, playwright, @wordpress/jest-*, @wordpress/babel-*, @wordpress/browserslist-config), Phase 2 (@testing-library/{react,jest-dom,dom}), Phase 3 partial (@woocommerce/{currency,explat,number}). | |||
There was a problem hiding this comment.
Just pointing out - there's two changelogs
There was a problem hiding this comment.
This was originally a stacked PR on top of #11614 but GitHub suggested a clean merge to develop and I left it as such.
There was a problem hiding this comment.
I marked #11614 as closed and will merge this one as a superseding version.
Changes proposed in this Pull Request
nwsapito version2.2.12- The newer version has a regression wheredocument.querySelector('label[for="size%f0%9f%98%86"]')returnsnulleven when the matching label exists —%characters in attribute selectors stop matchingts-jest→ 29.4.9ts-loader→ 9.5.7@playwright/test/playwright→ 1.59.1@wordpress/jest-console→ 8.44.0@wordpress/jest-preset-default→ 12.44.0@wordpress/babel-preset-default→ 8.44.0@wordpress/babel-plugin-makepot→ 6.44.0@wordpress/browserslist-config→ 6.44.0@testing-library/react→ 16.3.2@testing-library/jest-dom→ 6.9.1@testing-library/dom→ 10.4.1 (added; required peer for RTL 16)@types/testing-library__jest-dom→ 6.0.0@testing-library/user-event— kept at 13.5.0 (v14 deferred: API + fake-timer changes break ~14 suites)@woocommerce/currency→ 5.0.0@woocommerce/explat→ 2.4.0@woocommerce/number→ 2.5.0Deferred to follow-up PR(s)
@wordpress/i18nTransformedText<literal>typing → ~58 TS errors insprintf/createInterpolateElementcallsites@wordpress/{a11y,api-fetch,date,dom-ready,hooks,html-entities,url}i18n@6— must move together@woocommerce/navigation@wordpress/base-styles@media not (prefers-reduced-motion)) the project's sass can't parse@testing-library/user-eventpaste(el, data)→paste(data)) + fake-timer interaction needsuserEvent.setup()reworkTesting instructions
npm run lint:js— passes (5 pre-existing JSDoc warnings)npm run test:js— 2805 pass / 8 skipped (one flaky SIGTERM worker kill, unrelated to deps; passes in isolation)npm run build:client— cleannpm run changelogto add a changelog file, choosepatchto leave it empty if the change is not significant. You can add multiple changelog files in one PR by running this command a few times.Post merge