|
FAQ fodder (Re: exceptions and distinguishing between failures and errors): msg#00108java.junit.user
> hi all... > > i've been reading some of the threads regarding testing for > thrown exceptions, and read the wiki page http://c2.com/cgi/wiki? > CodingJavaUnitExceptionTests. i'm wondering whether, in the face > of exceptions (or otherwise), anyone really distinguishes between > failures and errors. Yes. If code throws an Exception that it shouldn't through, even under exceptional circumstances, I treat that as an error rather than a failure. One could argue that throwing the wrong exception type is a failure and not an error, but since it's impossible to distinguish between simply throwing the wrong exception type and something going horribly wrong, it is easiest to treat them both as errors. Mike, this is probably a FAQ. :) -- J. B. Rainsberger, President, Diaspar Software Services Let's write software that people understand. http://www.diasparsoftware.com/ telephone: +1 416 791-8603
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | RE: exceptions and distinguishing between failures and er rors, Mark Meyers |
|---|---|
| Next by Date: | distinguishing between failures and errors, pholser |
| Previous by Thread: | exceptions and distinguishing between failures and errors, pholser |
| Next by Thread: | distinguishing between failures and errors, pholser |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |