-
Notifications
You must be signed in to change notification settings - Fork 146
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
feat(await-async-query,await-async-utils,await-fire-event): support handling promises with jest-extended
's .toResolve
& .toRejects
#612
Conversation
jest-extended
's .toResolve
& .toRejects
This ESLint plugin is only about @testing-library testing frameworks. |
@MichaelDeBoey Can we rethink this? I would say this is a legit update for the rule. Such matchers can't be extended for the rule in |
Reading the rule README again, I think I misunderstood what @NickBolles was trying to do. I indeed think this has a place in our plugin! 👍 |
@MichaelDeBoey Great! I'll review this later. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change looks great! Since the change made to the hasClosestExpectResolvesRejects
method affects to other rules, could you update their docs to mention those matchers are valid too? Those rules are:
- await-async-utils
- await-fire-event
jest-extended
's .toResolve
& .toRejects
jest-extended
's .toResolve
& .toRejects
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@NickBolles Could you please also add tests for all these rules?
jest-extended
's .toResolve
& .toRejects
jest-extended
's .toResolve
& .toRejects
Good catch, I missed this! |
@NickBolles Just a reminder you have some CI checks to fix! |
@Belco90 sorry about such the delay on this. I've added tests for await-async-utils and await-fire-event, merged the latest from main and fixed the format issues. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Requested changes have been submitted.
🎉 This PR is included in version 5.9.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
@all-contributors please add @NickBolles for code,test, and doc |
I've put up a pull request to add @NickBolles! 🎉 |
🎉 This PR is included in version 6.0.0-alpha.14 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Checks
npm run generate:rules-list
)npm run generate:configs
)Changes
Add support for marking usage of jest-extendeds
toResolve
andtoReject
(docs) as valid handling of promises.Context