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

test(button): switch button tests to react testing library #1229

Merged
merged 11 commits into from
Jan 10, 2024

Conversation

anastasialanz
Copy link
Contributor

@anastasialanz anastasialanz commented Oct 6, 2023

Relates to #1197

This PR updates the Button component tests to use the React Testing Library and switches the test file to use TypeScript. It also adds @types packages for enzyme, jest, and jest-axe.

Screenshot 2024-01-04 at 1 01 13 PM

Validation Steps

  • Run yarn test and see a pass for src/components/Button/index.test.tsx
  • Verify that there is coverage for the Button component
  • Verify that the new test file uses TypeScript and is in the same directory as the component folder

@anastasialanz anastasialanz changed the title test: add react testing library and update button tests test(button): switch button tests to react testing library Oct 6, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Oct 6, 2023

Preview branch generated at https://rfc--testing-library.d1gko6en628vir.amplifyapp.com

@anastasialanz anastasialanz self-assigned this Oct 6, 2023
@anastasialanz anastasialanz force-pushed the rfc--testing-library branch 2 times, most recently from 857f3a1 to a64d896 Compare October 28, 2023 17:33
@anastasialanz anastasialanz marked this pull request as ready for review October 29, 2023 15:37
@anastasialanz anastasialanz requested a review from a team as a code owner October 29, 2023 15:37
@anastasialanz anastasialanz marked this pull request as draft October 29, 2023 15:48
@anastasialanz anastasialanz marked this pull request as ready for review January 4, 2024 19:18
Copy link
Member

@scurker scurker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work! 🎉

@anastasialanz anastasialanz merged commit 6cb7e9c into develop Jan 10, 2024
5 checks passed
@anastasialanz anastasialanz deleted the rfc--testing-library branch January 10, 2024 21:14
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.

2 participants