File Coverage

blib/lib/MooseX/Attribute/Dependent/Meta/Role/ApplicationToClass.pm
Criterion Covered Total %
statement 3 3 100.0
branch n/a
condition n/a
subroutine 1 1 100.0
pod n/a
total 4 4 100.0


line stmt bran cond sub pod time code
1             #
2             # This file is part of MooseX-Attribute-Dependent
3             #
4             # This software is Copyright (c) 2017 by Moritz Onken.
5             #
6             # This is free software, licensed under:
7             #
8             # The (three-clause) BSD License
9             #
10             package MooseX::Attribute::Dependent::Meta::Role::ApplicationToClass;
11             $MooseX::Attribute::Dependent::Meta::Role::ApplicationToClass::VERSION = '1.1.4';
12 3     3   770 use Moose::Role;
  3         9057  
  3         21  
13              
14             around apply => sub {
15             my $orig = shift;
16             my $self = shift;
17             my $role = shift;
18             my $class = shift;
19             $class =
20             Moose::Util::MetaRole::apply_metaroles(
21             for => $class,
22             class_metaroles => {
23             (Moose->VERSION >= 1.9900
24             ? (class =>
25             ['MooseX::Attribute::Dependent::Meta::Role::Class'])
26             : (constructor =>
27             ['MooseX::Attribute::Dependent::Meta::Role::Method::Constructor'])),
28             });
29             $self->$orig( $role, $class );
30             };
31              
32             1;
33              
34             __END__
35              
36             =pod
37              
38             =encoding UTF-8
39              
40             =head1 NAME
41              
42             MooseX::Attribute::Dependent::Meta::Role::ApplicationToClass
43              
44             =head1 VERSION
45              
46             version 1.1.4
47              
48             =head1 AUTHOR
49              
50             Moritz Onken
51              
52             =head1 COPYRIGHT AND LICENSE
53              
54             This software is Copyright (c) 2017 by Moritz Onken.
55              
56             This is free software, licensed under:
57              
58             The (three-clause) BSD License
59              
60             =cut