Revert most of the conversion to Test::Fatal so we can redo it
[gitmo/Moose.git] / t / 010_basics / 017_error_handling.t
index 79222d3..542c79c 100644 (file)
@@ -4,7 +4,7 @@ use strict;
 use warnings;
 
 use Test::More;
-use Test::Fatal;
+use Test::Exception;
 
 # This tests the error handling in Moose::Object only
 
@@ -13,12 +13,12 @@ use Test::Fatal;
     use Moose;
 }
 
-like exception { Foo->new('bad') }, qr/^\QSingle parameters to new() must be a HASH ref/,
+throws_ok { Foo->new('bad') } qr/^\QSingle parameters to new() must be a HASH ref/,
           'A single non-hashref arg to a constructor throws an error';
-like exception { Foo->new(undef) }, qr/^\QSingle parameters to new() must be a HASH ref/,
+throws_ok { Foo->new(undef) } qr/^\QSingle parameters to new() must be a HASH ref/,
           'A single non-hashref arg to a constructor throws an error';
 
-like exception { Foo->does() }, qr/^\QYou must supply a role name to does()/,
+throws_ok { Foo->does() } qr/^\QYou must supply a role name to does()/,
           'Cannot call does() without a role name';
 
 done_testing;