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

Support chai includeDeepMembers #140

Open
domoritz opened this issue Dec 11, 2018 · 2 comments
Open

Support chai includeDeepMembers #140

domoritz opened this issue Dec 11, 2018 · 2 comments

Comments

@domoritz
Copy link

It would be great if the library supported https://www.chaijs.com/api/assert/#method_includedeepmembers

@skovhus
Copy link
Owner

skovhus commented Dec 12, 2018

PRs are more than welcome. Are you up for creating one? Codemods are fun to write. :)

@domoritz
Copy link
Author

Unfortunately, I'm pretty swamped right now.

But I can suggest a translation I ended up applying by hand:

assert.includeDeepMembers(actual, [...expected])

should become for one expected value

expect(actual).toContainEqual(expected)

or this for multiple expected values

expect(actual).toEqual(expect.arrayContaining(expected))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants