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

Fix Jest test mocks #58

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Fix Jest test mocks #58

wants to merge 2 commits into from

Conversation

facuacostag
Copy link

@facuacostag facuacostag commented Sep 10, 2024

Issue

Version 4.3.0 changed how files were exported in the package.json as you can see in this commit. If you were mocking the library on Jest so tests could pass, the new configuration wasn't allowing Jest to find the package to be mocked.

Screenshot 2024-09-10 at 09 56 34

Solution

Adding require to to each of the exports solves the issue and allows Jest to work again.

@facuacostag
Copy link
Author

@microsoft-github-policy-service agree

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

Successfully merging this pull request may close these issues.

3 participants