Test "warnings" instead of failures?

147 views
Skip to first unread message

Aseem Kishore

unread,
Jan 9, 2014, 7:06:01 PM1/9/14
to moc...@googlegroups.com
Hi there,

Longtime user and fan of Mocha. Really nice work and thanks as always for all the amazing contributions to the Node world.

I'm running into a tricky timing bug that causes a few of my tests (just 1-2%) to fail randomly. This breaks my CI, which is cumbersome since there are many tests and we haven't optimized CI and test performance.

So for now, I'd love to be able to mark those test cases as "okay to fail". I know I can skip them, but I'd like to still run them, so I stay aware of whether (and how often) they're still failing. But, I wouldn't like Mocha to return a non-zero exit code if only those tests fail. Sort of like "warnings" rather than "failures".

Is that possible? If not, is that a feature you'd be open to adding?

Thanks!

Aseem



Devin Weaver

unread,
Feb 14, 2014, 1:41:12 PM2/14/14
to moc...@googlegroups.com
I soooo +1 this feature!

James M. Greene

unread,
Feb 15, 2014, 10:12:18 AM2/15/14
to moc...@googlegroups.com
Prior art:
.NET's MSUnit test framework has an `Inconclusive` assertion for this concept. Oddly, though, inconclusive tests still result in a failure exit code (WTF).
Reply all
Reply to author
Forward
0 new messages