develooper Front page | perl.perl5.porters | Postings from August 2001

Re: Request for testing FAQs

Thread Previous | Thread Next
From:
Philip Newton
Date:
August 23, 2001 22:05
Subject:
Re: Request for testing FAQs
Message ID:
bks8oto21ri387vgm58gofigr9cr13vnes@4ax.com
On Tue, 21 Aug 2001 17:56:22 -0400, schwern@pobox.com (Michael G Schwern) wrote:

> =head2 How do I test that my code handles failure gracefully?

Related to this:

=head2 How can I simulate failures to make sure that my code does the Right
Thing in the face of them?

For example, how does one arrange for a database connection to be dropped
between $sth->prepare and $sth->execute, or between execute and fetch? Or for a
file to disappear between "-e ($file)" and "open FILE, $file"? Etc.

Cheers,
Philip

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About