lib/Mite/App.pm.mite.pm

filter: Statementstmt 75.1% 115 / 153 Branchbran 36.7% 25 / 68 Conditioncond 25.0% 12 / 48 MC/DCmcdc 0.0% 0 / 31 Subroutinesub 64.5% 20 / 31 Podpod 0.0% 0 / 7 totaltotal 50.8% 172 / 338 CC 53 SCAR 31.2
CC
53
Cov
57%
DOES
72.0
new
53.5
DESTROY
13.1
CRAP 22.7
« lib/Mite/App/Command/preview.pm.mite.pm ↑ Summary lib/Mite/Trait/HasMOP.pm.mite.pm »
1 {
2  
3 24 package Mite::App;
4 24 ▶ use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 24 ▶ use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 24 ▶ no warnings qw( once void );
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 24 our $USES_MITE = "Mite::Class";
9 24 our $MITE_SHIM = "Mite::Shim";
10 24 our $MITE_VERSION = "0.013000";
11  
12 # Mite keywords
13 24 ▶ BEGIN {
Subroutine BEGIN: called CC=1 SCAR=1.2
14 24 my ( $SHIM, $CALLER ) = ( "Mite::Shim", "Mite::App" );
15 (
16 *after, *around, *before, *extends, *field,
17 *has, *param, *signature_for, *with
18 )
19 24 = do {
20  
21 package Mite::Shim;
22 24 ▶ no warnings 'redefine';
Subroutine BEGIN: called CC=1 SCAR=0.0
23 (
24 0 ▶ sub { $SHIM->HANDLE_after( $CALLER, "class", @_ ) },
Subroutine __ANON__: not called CC=1 SCAR=6.9
25 0 ▶ sub { $SHIM->HANDLE_around( $CALLER, "class", @_ ) },
Subroutine __ANON__: not called CC=1 SCAR=6.9
26 0 ▶ sub { $SHIM->HANDLE_before( $CALLER, "class", @_ ) },
Subroutine __ANON__: not called CC=1 SCAR=6.9
27 0 ▶ sub { },
Subroutine __ANON__: not called CC=1 SCAR=0.0
28 0 ▶ sub { $SHIM->HANDLE_has( $CALLER, field => @_ ) },
Subroutine __ANON__: not called CC=1 SCAR=6.9
29 72 ▶ sub { $SHIM->HANDLE_has( $CALLER, has => @_ ) },
Subroutine __ANON__: called CC=1 SCAR=0.0
30 0 ▶ sub { $SHIM->HANDLE_has( $CALLER, param => @_ ) },
Subroutine __ANON__: not called CC=1 SCAR=6.9
31 0 ▶ sub { $SHIM->HANDLE_signature_for( $CALLER, "class", @_ ) },
Subroutine __ANON__: not called CC=1 SCAR=6.9
32 0 ▶ sub { $SHIM->HANDLE_with( $CALLER, @_ ) },
Subroutine __ANON__: not called CC=1 SCAR=6.9
33 24 );
34 };
35 }
36  
37 # Mite imports
38 24 ▶ BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
39 24 require Scalar::Util;
40 24 *STRICT = \&Mite::Shim::STRICT;
41 24 *bare = \&Mite::Shim::bare;
42 24 *blessed = \&Scalar::Util::blessed;
43 24 *carp = \&Mite::Shim::carp;
44 24 *confess = \&Mite::Shim::confess;
45 24 *croak = \&Mite::Shim::croak;
46 24 *false = \&Mite::Shim::false;
47 24 *guard = \&Mite::Shim::guard;
48 24 *lazy = \&Mite::Shim::lazy;
49 24 *lock = \&Mite::Shim::lock;
50 24 *ro = \&Mite::Shim::ro;
51 24 *rw = \&Mite::Shim::rw;
52 24 *rwp = \&Mite::Shim::rwp;
53 24 *true = \&Mite::Shim::true;
54 24 *unlock = \&Mite::Shim::unlock;
55 }
56  
57 # Gather metadata for constructor and destructor
58 24 ▶ sub __META__ {
Subroutine __META__: called CC=4 SCAR=14.3
59 24 ▶ no strict 'refs';
Subroutine BEGIN: called CC=1 SCAR=0.0
60 24 my $class = shift;
61 24 ▶ $class = ref($class) || $class;
Condition33%1/3
ref $class || $class
l!l&&r!l&&!r
0240
MC/DC0%0/2
ref $class || $class
ref $class $class
Truth table33%1/3
A || B
A= ref $classB= $class
ABresult
1X1
011
000
62 24 my $linear_isa = mro::get_linear_isa($class);
63 return {
64 BUILD => [
65 24 ▶ map { ( *{$_}{CODE} ) ? ( *{$_}{CODE} ) : () }
Branch: 1 branch
BranchTrueFalseTotal
*{$_;}{'CODE'} ? : 24 0 24
66 24 map { "$_\::BUILD" } reverse @$linear_isa
67 ],
68 DEMOLISH => [
69 0 ▶ map { ( *{$_}{CODE} ) ? ( *{$_}{CODE} ) : () }
Branch: 1 branch
BranchTrueFalseTotal
*{$_;}{'CODE'} ? : 0 24 24
70 24 map { "$_\::DEMOLISH" } @$linear_isa
71 ],
72 HAS_BUILDARGS => $class->can('BUILDARGS'),
73 HAS_FOREIGNBUILDARGS => $class->can('FOREIGNBUILDARGS'),
74 };
75 }
76  
77 # Standard Moose/Moo-style constructor
78 24 ▶ sub new {
Subroutine new: called CC=19 SCAR=39.8
Pod undocumented
79 24 ▶ my $class = ref( $_[0] ) ? ref(shift) : shift;
Branch: 1 branch
BranchTrueFalseTotal
ref $_[0] ? : 0 24 24
80 24 ▶ my $meta = ( $Mite::META{$class} ||= $class->__META__ );
Condition33%1/3
$Mite::META{$class} ||= $class->__META__
l!l&&r!l&&!r
0240
MC/DC0%0/2
$Mite::META{$class} ||= $class->__META__
$Mite::META{$class} $class->__META__
Truth table33%1/3
A ||= B
A= $Mite::META{$class}B= $class->__META__
ABresult
1X1
011
000
81 24 my $self = bless {}, $class;
82 my $args =
83 $meta->{HAS_BUILDARGS}
84 ? $class->BUILDARGS(@_)
85 0 ▶ : { ( @_ == 1 ) ? %{ $_[0] } : @_ };
Branch: 2 branches
BranchTrueFalseTotal
$meta->{'HAS_BUILDARGS'} ? : 0 24 24
@_ == 1 ? : 0 24 24
86 24 my $no_build = delete $args->{__no_BUILD__};
87  
88 # Attribute commands (type: HashRef[Object])
89 # has declaration, file lib/Mite/App.pm, line 22
90 24 do {
91 my $value =
92 24 ▶ exists( $args->{"commands"} ) ? $args->{"commands"} : {};
Branch: 1 branch
BranchTrueFalseTotal
exists $args->{'commands'} ? : 0 24 24
93 24 ▶ do {
Branch: 1 branch
BranchTrueFalseTotal
do { package Mite::Shim; ref $value eq "HASH" and do { my $ok = 1; foreach my $i (values %{$value;}) { $ok = 0, last unless do { builtin::blessed($i) }; } ; $ok } } or croak("Type check failed in constructor: %s should be %s", "commands", "HashRef[Object]") 24 0 24
94  
95 package Mite::Shim;
96 24 ▶ ( ref($value) eq 'HASH' ) and do {
Condition33%1/3
ref $value eq 'HASH' && do { my $ok = 1; foreach my $i (values %{$value;}) { $ok = 0, last unless do { builtin::blessed($i) }; } ; $ok }
!ll&&!rl&&r
0024
MC/DC0%0/2
ref $value eq 'HASH' && do { my $ok = 1; foreach my $i (values %{$value;}) { $ok = 0, last unless do { builtin::blessed($i) }; } ; $ok }
ref $value eq 'HASH' do { my $ok = 1; foreach my $i (values %{$value;}) { $ok = 0, last unless do { builtin::blessed($i) }; } ; $ok }
Truth table33%1/3
A && B
A= ref $value eq 'HASH'B= do { my $ok = 1; foreach my $i (values %{$value;}) { $ok = 0, last unless do { builtin::blessed($i) }; } ; $ok }
ABresult
0X0
100
111
97 24 my $ok = 1;
98 24 for my $i ( values %{$value} ) {
99 ( $ok = 0, last )
100 unless (
101 0 ▶ do {
Branch: 1 branch
BranchTrueFalseTotal
unless do { builtin::blessed($i) } 0 0 0
102  
103 package Mite::Shim;
104 24 ▶ use Scalar::Util ();
Subroutine BEGIN: called CC=1 SCAR=0.0
105 0 Scalar::Util::blessed($i);
106 }
107 );
108 };
109 24 $ok;
110 }
111 }
112 or croak "Type check failed in constructor: %s should be %s",
113 "commands", "HashRef[Object]";
114 24 $self->{"commands"} = $value;
115 };
116  
117 # Attribute kingpin (type: Object)
118 # has declaration, file lib/Mite/App.pm, line 28
119 24 ▶ if ( exists $args->{"kingpin"} ) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $args->{"kingpin"}) 0 24 24
120 0 ▶ blessed( $args->{"kingpin"} )
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($args->{"kingpin"}) or croak("Type check failed in constructor: %s should be %s", "kingpin", "Object") 0 0 0
121 or croak "Type check failed in constructor: %s should be %s",
122 "kingpin", "Object";
123 0 $self->{"kingpin"} = $args->{"kingpin"};
124 }
125  
126 # Attribute project (type: Mite::Project)
127 # has declaration, file lib/Mite/App.pm, line 36
128 24 ▶ if ( exists $args->{"project"} ) {
Branch: 1 branch
BranchTrueFalseTotal
if (exists $args->{"project"}) 0 24 24
129 blessed( $args->{"project"} )
130 0 ▶ && $args->{"project"}->isa("Mite::Project")
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($args->{"project"}) and $args->{"project"}->isa("Mite::Project") or croak("Type check failed in constructor: %s should be %s", "project", "Mite::Project") 0 0 0
Condition0%0/3
builtin::blessed($args->{"project"}) and $args->{"project"}->isa("Mite::Project")
!ll&&!rl&&r
000
MC/DC0%0/2
builtin::blessed($args->{"project"}) and $args->{"project"}->isa("Mite::Project")
builtin::blessed($args->{"project"}) $args->{"project"}->isa("Mite::Project")
Truth table0%0/3
A and B
A= builtin::blessed($args->{"project"})B= $args->{"project"}->isa("Mite::Project")
ABresult
0X0
100
111
131 or croak "Type check failed in constructor: %s should be %s",
132 "project", "Mite::Project";
133 0 $self->{"project"} = $args->{"project"};
134 }
135  
136 # Call BUILD methods
137 24 ▶ $self->BUILDALL($args) if ( !$no_build and @{ $meta->{BUILD} || [] } );
Branch: 1 branch
BranchTrueFalseTotal
if not $no_build and @{$meta->{"BUILD"} or [];} 24 0 24
Condition40%2/5
not $no_build and @{$meta->{"BUILD"} or [];}
!ll&&!rl&&r
0024
$meta->{'BUILD'} || []
l!l
240
MC/DC0%0/2
not $no_build and @{$meta->{"BUILD"} or [];}
not $no_build @{$meta->{"BUILD"} or [];}
MC/DC0%0/1
$meta->{'BUILD'} || []
$meta->{'BUILD'}
Truth table33%1/3
not(A) and B
A= not $no_buildB= @{$meta->{"BUILD"} or [];}
ABresult
0X0
100
111
Truth table50%1/2
A
A= $meta->{'BUILD'}
Aresult
11
00
138  
139 # Unrecognized parameters
140 my @unknown = grep not(/\A(?:commands|kingpin|project)\z/),
141 24 keys %{$args};
142 @unknown
143 24 ▶ and croak(
Branch: 1 branch
BranchTrueFalseTotal
@unknown and croak('Unexpected keys in constructor: ' . join(", ", sort(@unknown))) 0 24 24
144 "Unexpected keys in constructor: " . join( q[, ], sort @unknown ) );
145  
146 24 return $self;
147 }
148  
149 # Used by constructor to call BUILD methods
150 24 ▶ sub BUILDALL {
Subroutine BUILDALL: called CC=4 SCAR=15.2
Pod undocumented
151 24 my $class = ref( $_[0] );
152 24 ▶ my $meta = ( $Mite::META{$class} ||= $class->__META__ );
Condition33%1/3
$Mite::META{$class} ||= $class->__META__
l!l&&r!l&&!r
2400
MC/DC0%0/2
$Mite::META{$class} ||= $class->__META__
$Mite::META{$class} $class->__META__
Truth table33%1/3
A ||= B
A= $Mite::META{$class}B= $class->__META__
ABresult
1X1
011
000
153 24 ▶ $_->(@_) for @{ $meta->{BUILD} || [] };
Condition50%1/2
$meta->{'BUILD'} || []
l!l
240
MC/DC0%0/1
$meta->{'BUILD'} || []
$meta->{'BUILD'}
Truth table50%1/2
A
A= $meta->{'BUILD'}
Aresult
11
00
154 }
155  
156 # Destructor should call DEMOLISH methods
157 24 ▶ sub DESTROY {
Subroutine DESTROY: called CC=7 SCAR=25.7
158 24 my $self = shift;
159 24 ▶ my $class = ref($self) || $self;
Condition33%1/3
ref $self || $self
l!l&&r!l&&!r
2400
MC/DC0%0/2
ref $self || $self
ref $self $self
Truth table33%1/3
A || B
A= ref $selfB= $self
ABresult
1X1
011
000
160 24 ▶ my $meta = ( $Mite::META{$class} ||= $class->__META__ );
Condition33%1/3
$Mite::META{$class} ||= $class->__META__
l!l&&r!l&&!r
2400
MC/DC0%0/2
$Mite::META{$class} ||= $class->__META__
$Mite::META{$class} $class->__META__
Truth table33%1/3
A ||= B
A= $Mite::META{$class}B= $class->__META__
ABresult
1X1
011
000
161 24 ▶ my $in_global_destruction =
Branch: 1 branch
BranchTrueFalseTotal
defined ${^GLOBAL_PHASE} ? : 24 0 24
162 defined ${^GLOBAL_PHASE}
163 ? ${^GLOBAL_PHASE} eq 'DESTRUCT'
164 : Devel::GlobalDestruction::in_global_destruction();
165 24 ▶ for my $demolisher ( @{ $meta->{DEMOLISH} || [] } ) {
Condition50%1/2
$meta->{'DEMOLISH'} || []
l!l
240
MC/DC0%0/1
$meta->{'DEMOLISH'} || []
$meta->{'DEMOLISH'}
Truth table50%1/2
A
A= $meta->{'DEMOLISH'}
Aresult
11
00
166 0 my $e = do {
167 0 local ( $?, $@ );
168 0 eval { $demolisher->( $self, $in_global_destruction ) };
169 0 $@;
170 };
171 24 ▶ no warnings 'misc'; # avoid (in cleanup) warnings
Subroutine BEGIN: called CC=1 SCAR=0.0
172 0 ▶ die $e if $e; # rethrow
Branch: 1 branch
BranchTrueFalseTotal
if $e 0 0 0
173 }
174 24 return;
175 }
176  
177 my $__XS = !$ENV{PERL_ONLY}
178 24 ▶ && eval { require Class::XSAccessor; Class::XSAccessor->VERSION("1.19") };
Condition33%1/3
!$ENV{'PERL_ONLY'} && eval { do { require Class::XSAccessor; 'Class::XSAccessor'->VERSION('1.19') } }
!ll&&!rl&&r
0024
MC/DC0%0/2
!$ENV{'PERL_ONLY'} && eval { do { require Class::XSAccessor; 'Class::XSAccessor'->VERSION('1.19') } }
!$ENV{'PERL_ONLY'} eval { do { require Class::XSAccessor; 'Class::XSAccessor'->VERSION('1.19') } }
Truth table33%1/3
not(A) && B
A= !$ENV{'PERL_ONLY'}B= eval { do { require Class::XSAccessor; 'Class::XSAccessor'->VERSION('1.19') } }
ABresult
0X0
100
111
179  
180 # Accessors for commands
181 # has declaration, file lib/Mite/App.pm, line 22
182 24 ▶ if ($__XS) {
Branch: 1 branch
BranchTrueFalseTotal
if ($__XS) { } 24 0 24
183 24 Class::XSAccessor->import(
184 chained => 1,
185 "getters" => { "commands" => "commands" },
186 );
187 }
188 else {
189 0 ▶ *commands = sub {
Subroutine __ANON__: not called CC=2 SCAR=17.9
190 0 ▶ @_ == 1 or croak('Reader "commands" usage: $self->commands()');
Branch: 1 branch
BranchTrueFalseTotal
@_ == 1 or croak("Reader \"commands\" usage: \$self->commands()") 0 0 0
191 0 $_[0]{"commands"};
192 0 };
193 }
194  
195 # Accessors for kingpin
196 # has declaration, file lib/Mite/App.pm, line 28
197 24 ▶ sub _assert_blessed_kingpin {
Subroutine _assert_blessed_kingpin: called CC=4 SCAR=18.7
198 24 my $object = do {
199 (
200 exists( $_[0]{"kingpin"} ) ? $_[0]{"kingpin"} : (
201 24 ▶ $_[0]{"kingpin"} = do {
Branch: 1 branch
BranchTrueFalseTotal
exists $_[0]{'kingpin'} ? : 24 0 24
202 0 my $default_value = $_[0]->_build_kingpin;
203 0 ▶ blessed($default_value)
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($default_value) or croak("Type check failed in default: %s should be %s", "kingpin", "Object") 0 0 0
204 or croak(
205 "Type check failed in default: %s should be %s",
206 "kingpin", "Object" );
207 0 $default_value;
208 }
209 )
210 )
211 };
212 24 ▶ blessed($object) or croak("kingpin is not a blessed object");
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($object) or croak("kingpin is not a blessed object") 24 0 24
213 24 $object;
214 }
215  
216 210 ▶ sub kingpin {
Subroutine kingpin: called CC=4 SCAR=14.1
Pod undocumented
217 210 ▶ @_ == 1 or croak('Reader "kingpin" usage: $self->kingpin()');
Branch: 1 branch
BranchTrueFalseTotal
@_ == 1 or croak("Reader \"kingpin\" usage: \$self->kingpin()") 210 0 210
218 (
219 exists( $_[0]{"kingpin"} ) ? $_[0]{"kingpin"} : (
220 210 ▶ $_[0]{"kingpin"} = do {
Branch: 1 branch
BranchTrueFalseTotal
exists $_[0]{'kingpin'} ? : 186 24 210
221 24 my $default_value = $_[0]->_build_kingpin;
222 24 ▶ blessed($default_value)
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($default_value) or croak("Type check failed in default: %s should be %s", "kingpin", "Object") 24 0 24
223 or croak( "Type check failed in default: %s should be %s",
224 "kingpin", "Object" );
225 24 $default_value;
226 }
227 )
228 );
229 }
230  
231 # Delegated methods for kingpin
232 # has declaration, file lib/Mite/App.pm, line 28
233 24 ▶ sub _parse_argv { shift->_assert_blessed_kingpin->parse(@_) }
Subroutine _parse_argv: called CC=1 SCAR=0.0
234  
235 # Accessors for project
236 # has declaration, file lib/Mite/App.pm, line 36
237 49 ▶ sub _assert_blessed_project {
Subroutine _assert_blessed_project: called CC=5 SCAR=24.1
238 49 my $object = do {
239 (
240 exists( $_[0]{"project"} ) ? $_[0]{"project"} : (
241 49 ▶ $_[0]{"project"} = do {
Branch: 1 branch
BranchTrueFalseTotal
exists $_[0]{'project'} ? : 49 0 49
242 0 my $default_value = $_[0]->_build_project;
243 0 ▶ blessed($default_value)
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($default_value) and $default_value->isa("Mite::Project") or croak("Type check failed in default: %s should be %s", "project", "Mite::Project") 0 0 0
Condition0%0/3
builtin::blessed($default_value) and $default_value->isa("Mite::Project")
!ll&&!rl&&r
000
MC/DC0%0/2
builtin::blessed($default_value) and $default_value->isa("Mite::Project")
builtin::blessed($default_value) $default_value->isa("Mite::Project")
Truth table0%0/3
A and B
A= builtin::blessed($default_value)B= $default_value->isa("Mite::Project")
ABresult
0X0
100
111
244 && $default_value->isa("Mite::Project")
245 or croak(
246 "Type check failed in default: %s should be %s",
247 "project", "Mite::Project" );
248 0 $default_value;
249 }
250 )
251 )
252 };
253 49 ▶ blessed($object) or croak("project is not a blessed object");
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($object) or croak("project is not a blessed object") 49 0 49
254 49 $object;
255 }
256  
257 38 ▶ sub project {
Subroutine project: called CC=5 SCAR=17.2
Pod undocumented
258 38 ▶ @_ == 1 or croak('Reader "project" usage: $self->project()');
Branch: 1 branch
BranchTrueFalseTotal
@_ == 1 or croak("Reader \"project\" usage: \$self->project()") 38 0 38
259 (
260 exists( $_[0]{"project"} ) ? $_[0]{"project"} : (
261 38 ▶ $_[0]{"project"} = do {
Branch: 1 branch
BranchTrueFalseTotal
exists $_[0]{'project'} ? : 16 22 38
262 22 my $default_value = $_[0]->_build_project;
263 22 ▶ blessed($default_value)
Branch: 1 branch
BranchTrueFalseTotal
builtin::blessed($default_value) and $default_value->isa("Mite::Project") or croak("Type check failed in default: %s should be %s", "project", "Mite::Project") 22 0 22
Condition33%1/3
builtin::blessed($default_value) and $default_value->isa("Mite::Project")
!ll&&!rl&&r
0022
MC/DC0%0/2
builtin::blessed($default_value) and $default_value->isa("Mite::Project")
builtin::blessed($default_value) $default_value->isa("Mite::Project")
Truth table33%1/3
A and B
A= builtin::blessed($default_value)B= $default_value->isa("Mite::Project")
ABresult
0X0
100
111
264 && $default_value->isa("Mite::Project")
265 or croak( "Type check failed in default: %s should be %s",
266 "project", "Mite::Project" );
267 22 $default_value;
268 }
269 )
270 );
271 }
272  
273 # Delegated methods for project
274 # has declaration, file lib/Mite/App.pm, line 36
275 49 ▶ sub config { shift->_assert_blessed_project->config(@_) }
Subroutine config: called CC=1 SCAR=0.0
Pod undocumented
276  
277 # See UNIVERSAL
278 0 ▶ sub DOES {
Subroutine DOES: not called CC=8 SCAR=42.8
Pod undocumented
279 0 my ( $self, $role ) = @_;
280 0 our %DOES;
281 0 ▶ return $DOES{$role} if exists $DOES{$role};
Branch: 1 branch
BranchTrueFalseTotal
if exists $Mite::App::DOES{$role} 0 0 0
282 0 ▶ return 1 if $role eq __PACKAGE__;
Branch: 1 branch
BranchTrueFalseTotal
if $role eq __PACKAGE__ 0 0 0
283 0 ▶ if ( $INC{'Moose/Util.pm'}
Branch: 1 branch
BranchTrueFalseTotal
if ($INC{"Moose/Util.pm"} and my $meta = Moose::Util::find_meta(ref $self || $self)) 0 0 0
Condition0%0/6
$INC{"Moose/Util.pm"} and my $meta = Moose::Util::find_meta(ref $self || $self)
!ll&&!rl&&r
000
ref $self || $self
l!l&&r!l&&!r
000
MC/DC0%0/2
$INC{"Moose/Util.pm"} and my $meta = Moose::Util::find_meta(ref $self || $self)
$INC{"Moose/Util.pm"} my $meta = Moose::Util::find_meta(ref $self || $self)
MC/DC0%0/2
ref $self || $self
ref $self $self
Truth table0%0/3
A and B
A= $INC{"Moose/Util.pm"}B= my $meta = Moose::Util::find_meta(ref $self || $self)
ABresult
0X0
100
111
Truth table0%0/3
A || B
A= ref $selfB= $self
ABresult
1X1
011
000
284 and my $meta = Moose::Util::find_meta( ref $self or $self ) )
285 {
286 0 ▶ $meta->can('does_role') and $meta->does_role($role) and return 1;
Branch: 1 branch
BranchTrueFalseTotal
$meta->can("does_role") and $meta->does_role($role) and return 1 0 0 0
Condition0%0/3
$meta->can("does_role") and $meta->does_role($role)
!ll&&!rl&&r
000
MC/DC0%0/2
$meta->can("does_role") and $meta->does_role($role)
$meta->can("does_role") $meta->does_role($role)
Truth table0%0/3
A and B
A= $meta->can("does_role")B= $meta->does_role($role)
ABresult
0X0
100
111
287 }
288 0 return $self->SUPER::DOES($role);
289 }
290  
291 # Alias for Moose/Moo-compatibility
292 0 ▶ sub does {
Subroutine does: not called CC=1 SCAR=6.9
Pod undocumented
293 0 shift->DOES(@_);
294 }
295  
296 24 1;
297 }
« lib/Mite/App/Command/preview.pm.mite.pm ↑ Summary lib/Mite/Trait/HasMOP.pm.mite.pm »