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

babel-jest is unable to find mock when path includes "/" on Windows #4284

Closed
erik-inkapool opened this issue Aug 16, 2017 · 2 comments
Closed

Comments

@erik-inkapool
Copy link

erik-inkapool commented Aug 16, 2017

Do you want to request a feature or report a bug?
Reporting a bug

What is the current behavior?
Importing a module mock using import with babel-jest on Windows:

  • Does not work when importing from "foo/bar"
  • Does work when importing from "foo\bar"

If the current behavior is a bug, please provide the steps to reproduce and either a repl.it demo through https://repl.it/languages/jest or a minimal repository on GitHub that we can yarn install and yarn test.
https://github.com/erik-lundgren/jest-windows-module-resolve-issue

What is the expected behavior?
Importing a module mock on windows:

  • Should work when importing from "foo/bar"
  • Should not work when importing from "foo\bar" (unless I'm mistaken)

Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.
Jest config is practically nonexistent, see the repro repo.

Node: v8.4.0
npm: 5.3.0
Windows: 1607 (build 14393.1593)

@erik-inkapool erik-inkapool changed the title Unable to find mock when path includes "/" on Windows babel-jest is unable to find mock when path includes "/" on Windows Aug 16, 2017
@thymikee
Copy link
Collaborator

Isn't this already fixed in #4238?

@github-actions
Copy link

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.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants