X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F030_roles%2F043_conflict_many_methods.t;h=785d48feee9d9a5eb6d7839609b81a7cc4bea8f1;hb=a28e50e44945358d15eb19e4688573741a319fe0;hp=384f97f4dc4436b476313dc6017370c7dd147a25;hpb=1b806c9945d6c57dca3805ae7924571df08aec03;p=gitmo%2FMoose.git diff --git a/t/030_roles/043_conflict_many_methods.t b/t/030_roles/043_conflict_many_methods.t index 384f97f..785d48f 100644 --- a/t/030_roles/043_conflict_many_methods.t +++ b/t/030_roles/043_conflict_many_methods.t @@ -2,7 +2,7 @@ use strict; use warnings; -use Test::More tests => 2; +use Test::More; use Test::Exception; { @@ -29,17 +29,20 @@ use Test::Exception; sub bark { } } -package PracticalJoke; -use Moose; - -::throws_ok { - with 'Bomb', 'Spouse'; -} qr/Due to method name conflicts in roles 'Bomb' and 'Spouse', the methods 'explode' and 'fuse' must be implemented or excluded by 'PracticalJoke'/; - -::throws_ok { - with ( - 'Bomb', 'Spouse', - 'Caninish', 'Treeve', - ); -} qr/Due to a method name conflict in roles 'Caninish' and 'Treeve', the method 'bark' must be implemented or excluded by 'PracticalJoke'/; +{ + package PracticalJoke; + use Moose; + + ::throws_ok { + with 'Bomb', 'Spouse'; + } qr/Due to method name conflicts in roles 'Bomb' and 'Spouse', the methods 'explode' and 'fuse' must be implemented or excluded by 'PracticalJoke'/; + + ::throws_ok { + with ( + 'Bomb', 'Spouse', + 'Caninish', 'Treeve', + ); + } qr/Due to a method name conflict in roles 'Caninish' and 'Treeve', the method 'bark' must be implemented or excluded by 'PracticalJoke'/; +} +done_testing;