no automatic travis testing for wip/blocked branches
[gitmo/Moo.git] / xt / moo-consume-moose-role-multiple.t
CommitLineData
f7f5e02d 1use strictures 1;
2use Test::More;
3
4{
5 package RoleOne;
6 use Moose::Role;
7
8 has foo => ( is => 'rw' );
9}
10
11{
12 package RoleTwo;
13 use Moose::Role;
14
15 has bar => ( is => 'rw' );
16}
17
18{
19 package SomeClass;
20 use Moo;
21
22 with 'RoleOne', 'RoleTwo';
23}
24
25my $i = SomeClass->new( foo => 'bar', bar => 'baz' );
26is $i->foo, 'bar', "attribute from first role is correct";
27is $i->bar, 'baz', "attribute from second role is correct";
28
29done_testing;
30