From: Robert Buels Date: Mon, 9 Aug 2010 16:59:46 +0000 (-0700) Subject: added failing test for role composition X-Git-Tag: v0.18~16 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=f2aa2fe56cd9ddc1f49e9d47d81b85133ab6893a;p=gitmo%2FMooseX-ClassAttribute.git added failing test for role composition --- diff --git a/t/08-role-composition.t b/t/08-role-composition.t new file mode 100644 index 0000000..08a3356 --- /dev/null +++ b/t/08-role-composition.t @@ -0,0 +1,31 @@ +use strict; +use warnings; +use Test::More; + +lives_ok { + Bar->new->_connections; +} 'finds a class attribute under role composition'; + +done_testing; + +BEGIN { + +package Role; +use Moose::Role; +use MooseX::ClassAttribute; + +class_has '_connections' => ( + is => 'ro', + isa => 'HashRef', + default => sub { {} }, + ); + +package Role2; +use Moose::Role; + +package Bar; +use Moose; + +with ('Role2','Role'); + +}