test-lib/Car/Mercedes.pm

filter: Statementstmt 75.0% 9 / 12 Branchbran n/a Conditioncond 33.3% 1 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 50.0% 3 / 6 Podpod 0.0% 0 / 4 totaltotal 48.1% 13 / 27 CC 2 SCAR 6.2
CC
2
Cov
67%
new
2.5
openDoors
2.0
closeDoors
2.0
CRAP 1.9
« test-lib/Car/AbstractFactory.pm ↑ Summary test-lib/Car/Interface.pm »
1 package Car::Mercedes;
2  
3 3 ▶use Class::Interface;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 3 implements 'Car::Interface', 'Car::Runnable';
5  
6 3 ▶use base 'Car::German';
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 1 ▶sub new {
Subroutine new: called CC=2 SCAR=9.2
Pod undocumented
9 1 ▶ return bless( {}, ref($_[0]) || $_[0] );
Condition33%1/3
ref $_[0] || $_[0]
l!l&&r!l&&!r
010
MC/DC0%0/2
ref $_[0] || $_[0]
ref $_[0] $_[0]
Truth table33%1/3
A || B
A= ref $_[0]B= $_[0]
ABresult
1X1
011
000
10 }
11  
12 0 ▶sub openDoors {
Subroutine openDoors: not called CC=1 SCAR=6.9
Pod undocumented
13 0 print "Doors open upwards -- this ist eine Gullwing :->";
14 }
15 0 ▶sub closeDoors {
Subroutine closeDoors: not called CC=1 SCAR=6.9
Pod undocumented
16 0 print "Doors close downwards"
17 }
18  
19 0 ▶sub run {
Subroutine run: not called CC=1 SCAR=6.9
Pod undocumented
20 0 print "Look... I am flying over the german speeeeeedways"
21 }
22  
23 3 1;
« test-lib/Car/AbstractFactory.pm ↑ Summary test-lib/Car/Interface.pm »