libtest-exception-perl | module for testing exception-based code | Mehr ...
Test::Exception is a Perl test module that provides a few convenience methods for testing exception-based code. It is built with Test::Builder and plays happily with Test::More and friends. . Note that this module only checks for exceptions, so it ignores other methods of halting program executing - including exit(). If your code causes the Perl interpreter to exit, Test::Exception won't be able to catch it.