feat(expect-expect): support chained function names (#471)#508
feat(expect-expect): support chained function names (#471)#508G-Rath merged 3 commits intojest-community:masterfrom
Conversation
G-Rath
left a comment
There was a problem hiding this comment.
Cheers, thanks for this!
|
Thanks! |
|
Fixing the coverage turned out to be trickier than expected, since Added Does the trick :) |
|
Thanks for reviewing and merging in the PR!! ✨ |
|
🎉 This PR is included in version 23.4.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Interesting - I'll add a note to have a look into this as part of the maintenance run I have planned, just to make sure it's all good :) Now that you've changed the implementation, it's possible that the overload signature should be tweaked, but regardless your fix here seems to work so that's the main thing :D |
Added support for chained assertion function names and method calls. (see also #471)
This makes it easy to support 3rd party assertion libraries like SuperTest with the option
{ "assertFunctionNames": ["expect", "request.get.expect"] }Examples of correct code for deep assertion functions with the
{ "assertFunctionNames": ["expect", "tester.foo.expect"] }option: