Welcome to MSDN Blogs Sign in | Join | Help

Kavitak's WebLog

My space on the web...

Syndication

News

Kavita Kamani works at Microsoft. Everything here, though, is her personal opinion and is not read or approved by Microsoft before it is posted. No warranties or other guarantees will be offered as to the quality of the opinions or anything else offered here.
Testing exceptions

Keith Stobie, a test architect on the Indigo team has an interesting article on testing exceptions.

Though it is important to verify that the correct exceptions get raised when incorrect data is passed to a function, it is also important to check the state after the exception has happened. What happens when you pass incorrect data, get an exception (which is a expected result for your test), and try to pass correct data - do you still get the exception; if so, you know the method didnt clean its state propertly. Most people miss verifying post-conditions. Verifying that things return to normal can lead to some interesting bugs.

Published Sunday, January 25, 2004 2:32 PM by kavitak

Filed under:

Comments

# re: Testing exceptions @ Friday, May 21, 2004 7:11 PM

What kind of inaccuracies? I would be happy to learn.

kavita

Anonymous comments are disabled
© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement  
Page view tracker