-
Notifications
You must be signed in to change notification settings - Fork 205
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
Support for jest.mock() #97
Comments
Not sure to understand what the issue is. You said |
Oh nvm, I misread it. Hmm.. instead of using What do you think? |
that might work :) but it's probably issue not only with jest but also other mocking frameworks |
Sure, but I prefer having a custom setting by framework then than having to force people using a different syntax for their tests ;) |
Oh, that's a shame, being able to use |
I believe we can also add support for |
Sure (#126) |
Hey,
I have following use-case: I'd like to mock require call with Jest testing framework, but when I do it this way:
file.js
file.test.js
then mock is not instatiated, as
foobar
is rewritten in tested file by this plugin to../../foobar
Ideally I would be able to do something like this:
and it would translate to:
what would result in proper require mocks.
Could this plugin support rewriting also
require.resolve(XXX)
?The text was updated successfully, but these errors were encountered: