No error description inside SuperAgent's "end"

157 views
Skip to first unread message

Dmitriy Navrotskyy

unread,
Apr 21, 2013, 11:46:03 PM4/21/13
to moc...@googlegroups.com
Hi everyone,

please look at this gist:


If I run it with mocha and one of the asserts inside the callback fails, the test is marked as failing, but there is no description about what happened (expected/actual value etc.).

Cheers

vision media [ Tj Holowaychuk ]

unread,
Apr 22, 2013, 11:07:44 AM4/22/13
to moc...@googlegroups.com
hmm there definitely should be, works for me :D


--
You received this message because you are subscribed to the Google Groups "Mocha" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mochajs+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Dmitriy Navrotskyy

unread,
Apr 22, 2013, 11:20:14 AM4/22/13
to moc...@googlegroups.com, t...@vision-media.ca
do you have a working example? maybe im doing something wrong.

thank you for fast response

vision media [ Tj Holowaychuk ]

unread,
Apr 22, 2013, 11:41:22 AM4/22/13
to moc...@googlegroups.com
I just threw from an .end( callback in Express to make sure it was reporting

Dmitriy Navrotskyy

unread,
Apr 25, 2013, 1:30:47 PM4/25/13
to moc...@googlegroups.com, t...@vision-media.ca
Hello again,

I have new information on this one. You were right, the error is thrown, but only after timeout. I set my timeout very high, so I never saw it. Seems like timeout is only exceeded in my "after" hook. It's a top level (root suite) hook which stops the http server (the server is started by the top level before hook). Maybe "done" is never called so it explains the behaviour. Is there a way to do it right?

Cheers and thanks for your help

Reply all
Reply to author
Forward
0 new messages