Revert most of the conversion to Test::Fatal so we can redo it
[gitmo/Moose.git] / t / 100_bugs / 030_coerce_without_coercion.t
index 120f763..7880688 100644 (file)
@@ -2,7 +2,7 @@ use strict;
 use warnings;
 
 use Test::More;
-use Test::Fatal;
+use Test::Exception;
 use Test::Moose;
 
 {
@@ -19,17 +19,17 @@ use Test::Moose;
 }
 
 with_immutable {
-    ok ! exception { Foo->new( x => {} ) },
+    lives_ok { Foo->new( x => {} ) }
     'Setting coerce => 1 without a coercion on the type does not cause an error in the constructor';
 
-    ok ! exception { Foo->new->x( {} ) },
+    lives_ok { Foo->new->x( {} ) }
     'Setting coerce => 1 without a coercion on the type does not cause an error when setting the attribut';
 
-    like exception { Foo->new( x => 42 ) },
+    throws_ok { Foo->new( x => 42 ) }
     qr/\QAttribute (x) does not pass the type constraint because/,
         'Attempting to provide an invalid value to the constructor for this attr still fails';
 
-    like exception { Foo->new->x(42) },
+    throws_ok { Foo->new->x(42) }
     qr/\QAttribute (x) does not pass the type constraint because/,
         'Attempting to provide an invalid value to the accessor for this attr still fails';
 }