Revision history for DBIx::Class
+ - new method "rethrow" for our exception objects
+
0.08001 2007-06-17 21:21:02
- Cleaned up on_connect handling for versioned
- removed DateTime use line from multi_create test
use lib qw(t/lib);
use DBICTest;
-plan tests => 6;
+plan tests => 8;
# Set up the "usual" sqlite for DBICTest
my $schema = DBICTest->init_schema;
# Basic check, normal exception
eval { throwex };
+my $e = $@; # like() seems to stringify $@
+like($@, $ex_regex);
+
+# Re-throw the exception with rethrow()
+eval { $e->rethrow };
+isa_ok( $@, 'DBIx::Class::Exception' );
like($@, $ex_regex);
# Now lets rethrow via exception_action