-
-
Notifications
You must be signed in to change notification settings - Fork 698
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
include/string/contain doc errors #15
Comments
One thing to note is that expect({ foo: 1, bar: 2 }).to.have.keys('foo', 'bar'); // this is strict; all or nothing
expect({ foo: 1, bar: 2 }).to.contain.keys('foo'); // this is inclusion This is achieved through Provided that the strict/inclusion feature for keys is not lost, I have no objections. Also, if you would be so kind to include some tests, that would be awesome :) |
I fixed the small typos for the docs. Is the second part, the feature request, something that you have had a chance to look into? It not, I'll slate it for 0.4.x. |
I ended up using similar ideas in chai-jquery, but haven't had time to do it for chai itself. Feel free to put it on the back burner. |
i like the idea so im going to leave this open so it doesn't fall into the abyss of closed tickets |
This has been implemented in the 0.6.x branch and will be in the next release :) /cc @vesln |
The
include
API doc has this exampleI think that's meant to be:
string
has this example:I think that's meant to be:
Though, if you did want
include
to work as both a function and a chaining property, it seems to be possible:I think it would be nice if both
include
andcontain
worked this way (i.e. they were synonyms, with the definition above):I can send a pull request if you agree.
The text was updated successfully, but these errors were encountered: