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

[chore] Unit tests: Expand expect with testing-library helpers #10169

Merged
merged 1 commit into from
Aug 28, 2024

Conversation

ThieryMichel
Copy link
Contributor

@ThieryMichel ThieryMichel commented Aug 28, 2024

Problem

Could not use matcher like expect(...).toBeDisabled in test.

Solution

initialize (import) @testing-library/jest-dom in jest test setup.

How To Test

Try to use testing library expect method, like toBeDisabled or toHaveAttribute.

Additional Checks

  • The PR targets master for a bugfix, or next for a feature
  • The PR includes unit tests (if not possible, describe why)
  • The PR includes one or several stories (if not possible, describe why)
  • The documentation is up to date

Also, please make sure to read the contributing guidelines.

@ThieryMichel ThieryMichel added the RFR Ready For Review label Aug 28, 2024
Copy link
Contributor

@slax57 slax57 left a comment

Choose a reason for hiding this comment

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

Sweet!

@slax57 slax57 added this to the 5.1.3 milestone Aug 28, 2024
@slax57 slax57 merged commit cbaaf5b into master Aug 28, 2024
14 checks passed
@slax57 slax57 deleted the extend-expect-with-testing-library branch August 28, 2024 12:29
@slax57 slax57 changed the title expand expect with testing-library helper for all tests [chore] Uni tests: Expand expect with testing-library helpers Aug 28, 2024
@slax57 slax57 changed the title [chore] Uni tests: Expand expect with testing-library helpers [chore] Unit tests: Expand expect with testing-library helpers Aug 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
RFR Ready For Review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants