X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F400_moose_util%2F008_method_mod_args.t;h=5919287ab627d57d672bb4cc1c2b0af003ea7e8f;hb=53a4d826caec4b82f5b23e0bc0a4e8e2f44243b9;hp=be7b29fa19f91cbf130ea2ab86bbe6ff994bf4cf;hpb=478b11a96fdfd6d0b2cc20214fb9e4645b6ef75c;p=gitmo%2FMoose.git diff --git a/t/400_moose_util/008_method_mod_args.t b/t/400_moose_util/008_method_mod_args.t index be7b29f..5919287 100644 --- a/t/400_moose_util/008_method_mod_args.t +++ b/t/400_moose_util/008_method_mod_args.t @@ -2,7 +2,7 @@ use strict; use warnings; use Test::More; -use Test::Fatal; +use Test::Exception; use Moose::Util qw( add_method_modifier ); my $COUNT = 0; @@ -14,13 +14,13 @@ my $COUNT = 0; sub bar { } } -ok ! exception { +lives_ok { add_method_modifier('Foo', 'before', [ ['foo', 'bar'], sub { $COUNT++ } ]); -}, 'method modifier with an arrayref'; +} 'method modifier with an arrayref'; -ok exception { +dies_ok { add_method_modifier('Foo', 'before', [ {'foo' => 'bar'}, sub { $COUNT++ } ]); -}, 'method modifier with a hashref'; +} 'method modifier with a hashref'; my $foo = Foo->new; $foo->foo;