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
Weird error thrown #80
Comments
i think i've seen this a few times now too, i'll check it out tomorrow |
Some info: Those errors occur when the tests are throwing errors (eg. the lib I am using). The original error thrown is: [TypeError: Object # has no method 'inState'] But somehow the Mocha runner throws the above [TypeError: Cannot set property 'failed' of undefined] errors as a response. |
hmm i cant seem to reproduce this now |
Try this:
It throws the errors I mentioned above. |
ah ok got it, it's when async |
ahahaha that tricky little bugger.. i got it |
I ran into same issues several times. It is definitely async issue, and the solution I found is that you need to call assertions within the callback, either after done. Here is my gist, https://gist.github.com/1392471 |
I just wasn't returning on the exception so it executed twice |
Is the error 1 and 2 supposed to be there?
|
hmm i think that might be due to the timer |
yup, reproduced it |
Should/could this also be fixed? It might confuse the users. |
of course |
I have this code in a test:
The test is passing. But when I change the returned value by person.isInState("Mood") to false I get the following errors:
It doesn't make much sense. It comes from the runner.
The text was updated successfully, but these errors were encountered: