8 my $attributes_applied = 0;
15 Moose::Exporter->setup_import_methods(
17 application_to_class =>
24 before apply_attributes => sub {
25 $attributes_applied++;
34 has bar => ( is => 'rw', default => 1 );
40 has foo => ( is => 'rw', default => 1 );
48 use namespace::autoclean;
50 with qw( RoleB RoleA );
52 __PACKAGE__->meta->make_immutable;
55 is($attributes_applied, 2);
59 package ComposeSeparate;
62 use namespace::autoclean;
67 __PACKAGE__->meta->make_immutable;
70 is($attributes_applied, 4);