Skip to content

Add a definition for TextMatch #52

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

Merged
merged 4 commits into from
Apr 11, 2018

Conversation

thchia
Copy link
Contributor

@thchia thchia commented Apr 11, 2018

What:
Update typings by adding a TextMatch type.

Why:
TypeScript consumers cannot use RegExp or functions in the query helpers, due to the argument being typed as string-only.

How:
Add a TextMatch type and replaced the string argument type for the various query helpers with it.

Checklist:

  • Documentation N/A
  • Tests N/A
  • Ready to be merged
  • Added myself to contributors table

@codecov
Copy link

codecov bot commented Apr 11, 2018

Codecov Report

Merging #52 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff          @@
##           master    #52   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files           1      1           
  Lines          18     18           
=====================================
  Hits           18     18

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 30ad9df...c2cdc0b. Read the comment docs.

kentcdodds
kentcdodds previously approved these changes Apr 11, 2018
Copy link
Member

@kentcdodds kentcdodds left a comment

Choose a reason for hiding this comment

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

Coolio!

@kentcdodds
Copy link
Member

Oops. Could you rebase and resolve merge conflicts? Just did the one in .all-contributorsrc then run npx kcd-scripts contributors generate to fix the README one 👍

kentcdodds
kentcdodds previously approved these changes Apr 11, 2018
Copy link
Member

@kentcdodds kentcdodds left a comment

Choose a reason for hiding this comment

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

Awesome. Thanks!

@thchia
Copy link
Contributor Author

thchia commented Apr 11, 2018

Hope I did it right... I was trying to actually rebase it rather than push another commit on but I came a little unstuck. Thanks for this library!

… with it.

docs: remove unnecessary variable in the fireEvent documentation (testing-library#51)
# Conflicts:
#	.all-contributorsrc
#	README.md
@thchia
Copy link
Contributor Author

thchia commented Apr 11, 2018

Sorry, tried again but it seems when I rebased the upstream changes it always thinks there is a conflict.

kentcdodds
kentcdodds previously approved these changes Apr 11, 2018
Copy link
Member

@kentcdodds kentcdodds left a comment

Choose a reason for hiding this comment

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

Super! Thanks!

@kentcdodds kentcdodds merged commit e38ce02 into testing-library:master Apr 11, 2018
julienw pushed a commit to julienw/react-testing-library that referenced this pull request Dec 20, 2018
* Fix query function names in example

Some function names in the example don't match the element.

* Add me as a contributor
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