-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug: An error occurs when invoking ESLint#lintFiles()
in Jest
#18407
Comments
I can reproduce this locally. Thanks for the detailed analysis of the cause! https://github.com/StewEucen/eslint-bug-with-jest?tab=readme-ov-file#cause
So it seems that in Node.js different operations may use different @nzakas perhaps |
|
The This only occurs when the Node.js process is launched with the |
|
I can update |
A new version of |
Here's a PR to update the dependency: #18416 |
@nzakas @mdjermanovic @fasttime
|
Environment
Node version: 20.12.2
npm version: 10.5.0
Local ESLint version: 9.1.1
Global ESLint version: 9.1.1
Operating System: macOS
What parser are you using?
Default (Espree)
What did you do?
Configuration
eslint.config.js
Actual code
Test Resources
tests/resources/indent.js
tests/resources/quotes.js
tests/resources/semi.js
What did you expect to happen?
I expect that Jest shows the log below
PASS tests/__tests__/eslint-bug.js ESLint Bug ✓ should not throw an error (121 ms) Test Suites: 1 passed, 1 total Tests: 1 passed, 1 total Snapshots: 0 total Time: 1.221 s, estimated 2 s Ran all test suites.
What actually happened?
An error
Result is not a promise.
is thrown.Link to Minimal Reproducible Example
https://github.com/StewEucen/eslint-bug-with-jest
Participation
Additional comments
I wrote details as the problem in
README.md
of this repositoryhttps://github.com/StewEucen/eslint-bug-with-jest
The text was updated successfully, but these errors were encountered: