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

Add a way to check a value is eql to someone #134

Open
emilioplatzer opened this issue Apr 26, 2015 · 0 comments
Open

Add a way to check a value is eql to someone #134

emilioplatzer opened this issue Apr 26, 2015 · 0 comments

Comments

@emilioplatzer
Copy link

expect(x).to.be.in([x1, x2, x3]) will be true if 'expect(x).to.eql(x1)` or x2 or x3.

The idea is to use with any object. Example:

expect(['encode', 'utf8']).be.in([ ['encode','utf8'], ['overwrite', false] ])

I couldn't use expect([x1, x2, x3]).to.include(x) because it uses indexOf doesn't work for objects (because implies ===).

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

No branches or pull requests

1 participant