-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Description
Self-service
- I'd be willing to implement a fix
Describe the bug
After upgrading to mocha v9.0.2 all tests started to fail. I worked with the mocha developers and they came to the conclusion that yarn pnp may not be recognizing CJS dynamic imports available with node v12.22+. Here are the details of the diagnostics by the mocha devs: mochajs/mocha#4693.
To reproduce
Link to demo repo.
- Clone demo repo
- Run
yarn installto install mocha, chai, and their dependencies - Run
yarn testand the console will return0 passing (1ms)
Environment
System:
OS: macOS 11.4
CPU: (16) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
Binaries:
Node: 14.15.5 - /private/var/folders/9n/y6fxtvls1w776645zpdf4n6n6qrsvq/T/xfs-b99b3208/node
Yarn: 2.4.2 - /private/var/folders/9n/y6fxtvls1w776645zpdf4n6n6qrsvq/T/xfs-b99b3208/yarn
npm: 6.14.11 - /usr/local/bin/npm
Additional context
Currently yarn test for "Validating Mocha" are also failing silently. Potentially because of this issue. Here is an example.
No response