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

Migrated SelectField AntD tests to @testing-library/react #1312

Merged
merged 3 commits into from
Apr 5, 2024

Conversation

kestarumper
Copy link
Member

I've encountered a lot of problems. Many related to fireEvent.change not working at all. AntD seems to be doing things differently when it comes to the role etc. It also does some virtualization which makes things harder.

Notes

  • Some elements only appear in the DOM when you "click" on the combobox
    • ...but you can't use fireEvent.click, it has to be fireEvent.mouseDown (see references)

Reference

@kestarumper kestarumper self-assigned this Mar 23, 2024
@github-actions github-actions bot added Area: Core Affects the uniforms package Area: Theme Affects some of the theme packages Theme: AntD Affects the uniforms-antd package labels Mar 23, 2024
Copy link

codecov bot commented Mar 23, 2024

Codecov Report

Attention: Patch coverage is 87.50000% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 94.61%. Comparing base (9dec81c) to head (e2aa01a).

Files Patch % Lines
packages/uniforms-antd/src/SelectField.tsx 87.50% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@                 Coverage Diff                 @@
##           select-field-tests    #1312   +/-   ##
===================================================
  Coverage               94.60%   94.61%           
===================================================
  Files                     231      231           
  Lines                    3821     3823    +2     
  Branches                 1029     1030    +1     
===================================================
+ Hits                     3615     3617    +2     
  Misses                     82       82           
  Partials                  124      124           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@zaxovaiko zaxovaiko merged commit b90343c into select-field-tests Apr 5, 2024
6 of 7 checks passed
@zaxovaiko zaxovaiko deleted the select-field-tests-antd branch April 5, 2024 10:24
@kestarumper kestarumper linked an issue Apr 7, 2024 that may be closed by this pull request
@kestarumper kestarumper changed the title Enable AntD SelectField tests suite Migrated SelectField AntD tests to @testing-library/react Apr 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Core Affects the uniforms package Area: Theme Affects some of the theme packages Theme: AntD Affects the uniforms-antd package
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

4 participants