-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
NodeUnit-like expect assertions #912
Comments
we can't do this sort of thing since we dont couple with any assertion library, but it's pretty easy to do little counters if you need to and do |
@visionmedia yeah I know, and this is what I've been doing for testing streams but such tests are verbose enough, and every little line added is getting painful. I just need to find a way to make a nice little util that does this automatically, but that requires knowing the internals of mocha and an assertion lib, and hope I can make them cooperate. Right now mocha api/internals aren't documented so not likely to do this soon... |
I don't mind the |
@visionmedia thanks for the references |
@visionmedia is there a global That would be ideal. |
yup, root-level ones outside of describes() are attached to the root suite named |
@visionmedia I see, once again thanks for clarifying!. I take it that this example is a demonstration of such global usage https://github.com/visionmedia/mocha/wiki/Assertion-counting |
NodeUnit's expect feature:
does indeed seem useful. If
mocha
has developer docs I'd see about hooking this in as a plugin.The text was updated successfully, but these errors were encountered: