updated dependents test
[gitmo/Moo.git] / t / has-before-extends.t
CommitLineData
3b0d7efd 1use strictures 1;
2use Test::More;
3
4{
5 package Fail1;
6
7 use Moo;
8
9 has 'attr1' => (is => 'ro');
10
11 package Fail2;
12
13 use Moo;
14
15 has 'attr2' => (is => 'ro');
16
17 extends 'Fail1';
18}
19
20my $new = Fail2->new({ attr1 => 'value1', attr2 => 'value2' });
21
22is($new->attr1, 'value1', 'inherited attr ok');
23is($new->attr2, 'value2', 'subclass attr ok');
24
25done_testing;