-
-
Notifications
You must be signed in to change notification settings - Fork 24
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
Not working with Jest #9
Comments
Can you try out v3.0.0? It improves the logic for finding the module to clear. |
Just tried, same result. Jest have its own |
@sinedied Use
(The implication is that you don't need this library when using Jest.) When Jest 24 is released, there will be a way to cache bust specific modules instead of the whole thing. |
@lonix1 That's what I ended up doing, but as Jest doesn't go through the original require, it doesn't use this lib, making the unit test somewhat useless 😞 |
When running unit tests with Jest, the
importFresh
function does not work properly, it always returns the same (cached?) module.Might be due to the fact that Jest patch
require
with its own implementation :/The text was updated successfully, but these errors were encountered: