Test: Use native Vite transforms for unit tests - #80997
Draft
ciampo wants to merge 1 commit into
Draft
Conversation
|
Size Change: 0 B Total Size: 7.76 MB |
This was referenced Jul 30, 2026
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 30, 2026 23:48
d779272 to
86413d3
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 30, 2026 23:48
01dd9ff to
9a765e2
Compare
|
Flaky tests detected in ccc5142. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/30598125515
|
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 00:38
86413d3 to
1551ea0
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 00:38
9a765e2 to
adcc20e
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 01:12
1551ea0 to
9529651
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 01:12
adcc20e to
e0a5a42
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 01:20
9529651 to
d5e3139
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 01:20
e0a5a42 to
5e35c37
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 01:45
7bf6188 to
987e70b
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 02:06
987e70b to
ccc5142
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 02:57
ccc5142 to
f9f8ded
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 02:57
4e3dd77 to
3eec742
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 19:21
3eec742 to
8f70fba
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 19:21
f9f8ded to
e75e488
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 19:36
8f70fba to
7ce22c8
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 19:36
e75e488 to
ddc3d8e
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 19:46
7ce22c8 to
3b5ef70
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 19:46
ddc3d8e to
8f6a343
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-05-browser-mode
branch
from
July 31, 2026 20:01
3b5ef70 to
474050f
Compare
ciampo
force-pushed
the
codex/vitest-consolidated-06-native-vite
branch
from
July 31, 2026 20:01
8f6a343 to
b563371
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #80855.
What?
TL;DR — transform changes: replace the private Babel-wide Vitest transform with Vite's official React/SWC path, remove the Jest-only block metadata transformer, and migrate the remaining internal agent-tool test to Vitest.
Why?
The final runner should use native Vite module handling rather than carry the legacy Jest/Babel execution pipeline into Vitest.
How?
@vitejs/plugin-react-swcwith the official Emotion SWC plugin.typescript-eslint.tools/agentstests to explicit Vitest imports.block.jsoninvalidation.Runtime requirements
@vitejs/plugin-react-swc@4.3.2requires Node^20.19.0 || >=22.12.0, matching Gutenberg's existing Node floor. The npm minimum remains>=10.2.3.Testing Instructions
npm run test:unit:routingandnpm run test:unit:conventions.npm run test:unit -- --runInBand.test/unitandtools/agents.Testing Instructions for Keyboard
Not applicable; this changes test infrastructure only.
Use of AI Tools
Codex assisted with implementation, compatibility checks, and verification. The resulting changes and snapshots were reviewed by the author.