Handling unittests that are designed to fail

Joseph Rushton Wakeling joseph.wakeling at webdrake.net
Wed Jun 5 05:31:58 PDT 2013


Hi all,

I'd like to design a unittest that will fail -- that is, it will trigger an
assert() or enforce() failure inside the function it is testing.

How would I go about doing this so that the unittest {} block will confirm the
failure and count this as a "pass"?

Thanks & best wishes,

    -- Joe


More information about the Digitalmars-d-learn mailing list