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

Migrate Unit Testing from jest-enzyme to react-testing-library #1536

Closed
aarishshahmohsin opened this issue Feb 3, 2024 · 4 comments
Closed
Assignees
Labels
bug Something isn't working no-issue-activity No issue activity

Comments

@aarishshahmohsin
Copy link
Contributor

Describe the bug
Unit testing on Talawa Admin is done using jest-enzyme which is a library that provides additional utility functions for testing React components with Jest and Enzyme. jest-enzyme does not support React 17 and above and hence an unofficial adapter @wojtekmaj/enzyme-adapter-react-17 is being used to make it compatible. This is a workaround and not the optimal solution to the problem.

To Reproduce
NA

Expected behavior
All tests of Talawa Admin should be written using react-testing-library instead of enzyme which requires an adapter.

Actual behavior
All tests are written using jest-enzyme which is not supported for React 17 and above without using unofficial adapters.

Screenshots
NA

Additional details
This would require refactoring of the entire testing suite.

@palisadoes
Copy link
Contributor

@aarishshahmohsin Do you want to be assigned this issue?

@aarishshahmohsin
Copy link
Contributor Author

@aarishshahmohsin Do you want to be assigned this issue?

yes.

Copy link

This issue did not get any activity in the past 10 days and will be closed in 180 days if no update occurs. Please check if the develop branch has fixed it and report again or close the issue.

@github-actions github-actions bot added the no-issue-activity No issue activity label Feb 14, 2024
@Cioppolo14
Copy link
Contributor

Closing this, the PR is merged so this is complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working no-issue-activity No issue activity
Projects
None yet
Development

No branches or pull requests

3 participants