-
-
Notifications
You must be signed in to change notification settings - Fork 6.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
Module ts-jest in transform not found. Solved? #6051
Comments
Looks like the same issue: #5563. I'll close this one, but please join discussion there with your findings. |
It's still broken!! |
|
It's still broken!! |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I want to report a bug
What is the current behavior?
I get an error running jest from a mapped network drive. Jest runs fine from a local drive.
I think this is related to:
#5563
Error
To repeat:
Open x:\test-typescript-app\ in VS Code and hit (F5) to debug it with (
vscode-jest-tests
configuration).and you should get the above error.
Open the same project from C:\test\test-typescript-app and the tests will run(tests didn't pass for me but at least it got that far).
test-typescript-app
was created withcreate-react-app my-app --scripts-version=react-scripts-ts
per create a typescriptI think I found the problem
It's in how
path#join
(now?) handles network paths atpath.join(prefix, aPath, moduleDir);
https://github.com/facebook/jest/blob/master/packages/jest-resolve/src/node_modules_paths.js#L62
Changing this line to
prefix = '';
gets the tests to start/finish.https://github.com/facebook/jest/blob/master/packages/jest-resolve/src/node_modules_paths.js#L38
I just think this is the regex and I'm a test noob. I got the tests in my other project to run with the VS Code Jest Extension by changing that line.
Maybe Line 35 should be
What is the expected behavior?
I expect tests to run rather than getting an error.
Please provide your exact Jest configuration
The commit adding jest config to package.json
Run
npx envinfo --preset jest
in your project directory and paste theresults here
Original issue found using VS Code's Jest plugin:
jest-community/vscode-jest#304
The text was updated successfully, but these errors were encountered: