oo/Lax.pm

filter: Statementstmt 52.9% 9 / 17 Branchbran 0.0% 0 / 4 Conditioncond 0.0% 0 / 2 MC/DCmcdc 0.0% 0 / 1 Subroutinesub 50.0% 3 / 6 Podpod 100% 1 / 1 totaltotal 41.9% 13 / 31 CC 4 SCAR 22.7
CC
4
Cov
39%
import
20.0
moo
2.0
__ANON__
2.0
CRAP 9.7
↑ Summary Moo/Lax.pm »
1 #
2 # This file is part of Moo-Lax
3 #
4 # This software is Copyright (c) 2014 by Damien Krotkine.
5 #
6 # This is free software, licensed under:
7 #
8 # The Artistic License 2.0 (GPL Compatible)
9 #
10 package oo::Lax;
11 1 $oo::Lax::VERSION = '2.00';
12 #ABSTRACT: Loads oo without turning warnings to fatal.
13  
14  
15 1 ▶use Moo::_Utils;
Subroutine BEGIN: called CC=1 SCAR=0.0
16  
17  
18 0 ▶sub moo {
Subroutine moo: not called CC=1 SCAR=6.9
Pod documented
19 0 print <<'EOMOO';
20 _________________
21 < Moo, but relax! >
22 -----------------
23 \ ^__^
24 \ (oo)\_______
25 (__)\ )\/\
26 ||----w |
27 || ||
28 EOMOO
29 0 exit 0;
30 }
31  
32 1 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
33 1 my $package;
34 0 ▶ sub import {
Subroutine import: not called CC=4 SCAR=30.0
35 0 ▶ moo() if $0 eq '-';
Branch: 1 branch
BranchTrueFalseTotal
if $0 eq "-" 0 0 0
36 0 ▶ $package = $_[1] || 'Class';
Condition0%0/2
$_[1] || 'Class'
l!l
00
MC/DC0%0/1
$_[1] || 'Class'
$_[1]
Truth table0%0/2
A
A= $_[1]
Aresult
11
00
37 0 ▶ if ($package =~ /^\+/) {
Branch: 1 branch
BranchTrueFalseTotal
if ($package =~ /^\+/) 0 0 0
38 0 $package =~ s/^\+//;
39 0 _load_module($package);
40 }
41 }
42 0 ▶ use Filter::Simple sub { s/^/package $package;\nuse Moo::Lax;\n/; }
Subroutine BEGIN: called CC=1 SCAR=0.2
Subroutine __ANON__: not called CC=1 SCAR=6.9
43 1 }
44  
45 1 1;
46  
47 __END__
↑ Summary Moo/Lax.pm »