Skip to content

chore(workspace): bump mocha v12 for esm config file#1626

Draft
thescientist13 wants to merge 1 commit into
masterfrom
chore/bump-mocha-12-esm-config
Draft

chore(workspace): bump mocha v12 for esm config file#1626
thescientist13 wants to merge 1 commit into
masterfrom
chore/bump-mocha-12-esm-config

Conversation

@thescientist13

@thescientist13 thescientist13 commented Jan 6, 2026

Copy link
Copy Markdown
Member

Related Issue

Mocha will soon start supporting an ESM based configuration file - https://github.com/mochajs/mocha/releases/tag/v12.0.0-beta-4

Documentation

N / A

Summary of Changes

  1. Bump mocha to v12 for ESM configuration files

TODO

  1. Double check import map snapshot changes - chore(workspace): bump mocha v12 for esm config file #1626 (comment)
  2. hmm... loaders test cases are running even for non-loader actions? - chore(workspace): bump mocha v12 for esm config file #1626 (comment)
  3. Wait for final v12 release

@thescientist13 thescientist13 self-assigned this Jan 6, 2026
@thescientist13 thescientist13 added the chore unit testing, maintenance, etc label Jan 6, 2026
@thescientist13 thescientist13 moved this from 🏗 In progress to 👀 In review in [Greenwood] Phase 10 - Ecosystem Compat Jan 6, 2026
@thescientist13

thescientist13 commented Jan 6, 2026

Copy link
Copy Markdown
Member Author

Yeah, some of these changes in the import map snapshot seem expected, just that packages do funny things. For instance, why would chokidar be in an import map?

➜  greenwood git:(master) ✗ yarn why chokidar
yarn why v1.22.22
[1/4] 🤔  Why do we have the module "chokidar"...?
[2/4] 🚚  Initialising dependency graph...
[3/4] 🔍  Finding dependency...
[4/4] 🚡  Calculating file sizes...
=> Found "chokidar@3.5.2"
info Reasons this module exists
   - "_project_#mocha" depends on it
   - Hoisted from "_project_#mocha#chokidar"
info Disk size without dependencies: "136KB"
info Disk size with unique dependencies: "356KB"
info Disk size with transitive dependencies: "680KB"
info Number of shared dependencies: 13
=> Found "netlify-cli#chokidar@3.5.3"
info This module exists because "_project_#@greenwood#plugin-adapter-netlify#netlify-cli" depends on it.
info Disk size without dependencies: "108KB"
info Disk size with unique dependencies: "328KB"
info Disk size with transitive dependencies: "652KB"
info Number of shared dependencies: 13
=> Found "livereload#chokidar@3.4.2"
info This module exists because "_project_#@greenwood#cli#livereload" depends on it.
info Disk size without dependencies: "108KB"
info Disk size with unique dependencies: "328KB"
info Disk size with transitive dependencies: "652KB"
info Number of shared dependencies: 13
=> Found "sass#chokidar@4.0.1"
info This module exists because "_project_#@greenwood#cli#@uswds#web-components#sass" depends on it.
info Disk size without dependencies: "304KB"
info Disk size with unique dependencies: "336KB"
info Disk size with transitive dependencies: "452KB"
info Number of shared dependencies: 2
✨  Done in 0.63s.

Which leads us to see why SASS is there...

➜  greenwood git:(master) ✗ yarn why sass
yarn why v1.22.22
[1/4] 🤔  Why do we have the module "sass"...?
[2/4] 🚚  Initialising dependency graph...
[3/4] 🔍  Finding dependency...
[4/4] 🚡  Calculating file sizes...
=> Found "sass@1.81.0"
info Reasons this module exists
   - "_project_#@greenwood#cli#@uswds#web-components" depends on it
   - Hoisted from "_project_#@greenwood#cli#@uswds#web-components#sass"
info Disk size without dependencies: "6.05MB"
info Disk size with unique dependencies: "7.04MB"
info Disk size with transitive dependencies: "7.57MB"
info Number of shared dependencies: 16
✨  Done in 1.27s.

And there's your answer, it's pulled in through USWDS. My guess is the rest are like this as well, and at least in this case, they are being deleted.

@thescientist13 thescientist13 moved this from 👀 In review to 🏗 In progress in [Greenwood] Phase 10 - Ecosystem Compat Jan 7, 2026
@thescientist13

Copy link
Copy Markdown
Member Author

OK, so the test failure issue (which we also see in #1595 ) seems to be a mocha issue after all, related to this issue - mochajs/mocha#4785 (comment)

@thescientist13 thescientist13 moved this from 🏗 In progress to 👀 In review in [Greenwood] Phase 10 - Ecosystem Compat Jan 7, 2026
@thescientist13 thescientist13 added v0.35.0 chore unit testing, maintenance, etc and removed chore unit testing, maintenance, etc labels Jun 21, 2026
@thescientist13 thescientist13 force-pushed the chore/bump-mocha-12-esm-config branch from 3d0504e to 55a7f2a Compare June 21, 2026 00:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore unit testing, maintenance, etc v0.35.0

Projects

Status: 👀 In review

Development

Successfully merging this pull request may close these issues.

1 participant