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

fix(buildQuery): get*Error functions receive same Arguments type as queryAllBy parameter #1041

Merged
merged 3 commits into from
Sep 30, 2021

Conversation

jacklaurencegaray
Copy link
Contributor

What:

The types for the arguments to GetErrorFunction are stuck at the default. At runtime, you can log ...args and see that the expected key and value are passed.

Why:

Described in this issue.

How:

Passed Argument generic to GetErrorFunction in buildQueries type definitions

Checklist:

  • Documentation added to the
    docs site
  • Tests
  • TypeScript definitions updated
  • Ready to be merged

@codesandbox-ci
Copy link

codesandbox-ci bot commented Sep 29, 2021

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit a413518:

Sandbox Source
react-testing-library-examples Configuration

@jacklaurencegaray jacklaurencegaray changed the title chore: type fix for buildQueries chore: extend types and tests for id related errors on buildQueries Sep 29, 2021
@codecov
Copy link

codecov bot commented Sep 30, 2021

Codecov Report

Merging #1041 (a413518) into main (99bc2c0) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##              main     #1041   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           25        25           
  Lines          920       920           
  Branches       284       284           
=========================================
  Hits           920       920           
Flag Coverage Δ
node-12 100.00% <ø> (ø)
node-14 100.00% <ø> (ø)
node-16.9.1 100.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


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 99bc2c0...a413518. Read the comment docs.

@eps1lon eps1lon changed the title chore: extend types and tests for id related errors on buildQueries fix(buildQuery): get*Error functions receive same Arguments type as queryAllBy parameter Sep 30, 2021
Copy link
Member

@eps1lon eps1lon left a comment

Choose a reason for hiding this comment

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

Thanks!

@eps1lon eps1lon added bug Something isn't working TypeScript labels Sep 30, 2021
@eps1lon eps1lon merged commit 6171979 into testing-library:main Sep 30, 2021
@eps1lon
Copy link
Member

eps1lon commented Sep 30, 2021

@all-contributors add @jacklaurencegaray for code

@allcontributors
Copy link
Contributor

@eps1lon

I've put up a pull request to add @jacklaurencegaray! 🎉

@github-actions
Copy link

🎉 This PR is included in version 8.7.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

Typescript: buildQueries should pass Arguments through to GetErrorFunction
3 participants