Skip to content
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

SyntaxError: Invalid or unexpected token when running from Jest #223

Open
Dizzienoo opened this issue Nov 2, 2021 · 1 comment
Open

Comments

@Dizzienoo
Copy link

(Thanks for reporting an issue to micromatch! If you haven't already read the contributor guidelines, Please do that now, then proceed to fill out the details below.)

Please describe the minimum necessary steps to reproduce this issue:

Install Jest (latest version) and create any test and try to run.

What is happening that shouldn't be?

Error returns:

G:\Users\Work\Documents\Gits\JestIssue\node_modules\micromatch\index.js:1
VW��

SyntaxError: Invalid or unexpected token
at wrapSafe (internal/modules/cjs/loader.js:1001:16)
at Module._compile (internal/modules/cjs/loader.js:1049:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
at Module.load (internal/modules/cjs/loader.js:950:32)
at Function.Module._load (internal/modules/cjs/loader.js:790:12)
at Module.require (internal/modules/cjs/loader.js:974:19)
at require (internal/modules/cjs/helpers.js:93:18)
at Object. (G:\Users\Work\Documents\Gits\JestIssue\node_modules\jest-haste-map\build\watchers\common.js:10:20)
at Module._compile (internal/modules/cjs/loader.js:1085:14)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
error Command failed with exit code 1.

What should be happening instead?

Test should run.

This seems to be an issue with micromatch as when I copy the development copy from 4.0.3 into the node_modules folder the problem stops.

Repo example of the problem:
https://github.com/Dizzienoo/JestIssue

@jonschlinkert
Copy link
Member

Sorry for the late reply. What version of node.js are (were) you running? Does it happen with the latest version of node?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants