Everything/Adapter/Base.pm

filter: Statementstmt 53.3% 8 / 15 Branchbran n/a Conditioncond 0.0% 0 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 40.0% 2 / 5 Podpod 0.0% 0 / 3 totaltotal 35.7% 10 / 28 CC 2 SCAR 10.4
CC
2
Cov
44%
write
6.0
new
2.0
BEGIN
1.0
CRAP 2.8
« Everything/Adapter.pm ↑ Summary Everything/Adapter/Test.pm »
1 package Measure::Everything::Adapter::Base;
2  
3 # ABSTRACT: Base class for adapters
4 4 our $VERSION = '1.003'; # VERSION
5  
6 4 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 4 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 0 ▶sub new {
Subroutine new: not called CC=1 SCAR=6.9
Pod undocumented
10 0 my $class = shift;
11 0 my $self = {@_};
12 0 bless $self, $class;
13 0 $self->init(@_);
14 0 return $self;
15 }
16  
17 0 ▶sub init { }
Subroutine init: not called CC=1 SCAR=0.0
Pod undocumented
18  
19 0 ▶sub write {
Subroutine write: not called CC=2 SCAR=17.9
Pod undocumented
20 0 ▶ my $class = ref( $_[0] ) || $_[0];
Condition0%0/3
ref $_[0] || $_[0]
l!l&&r!l&&!r
000
MC/DC0%0/2
ref $_[0] || $_[0]
ref $_[0] $_[0]
Truth table0%0/3
A || B
A= ref $_[0]B= $_[0]
ABresult
1X1
011
000
21 0 die "$class does not implement 'write'";
22 }
23  
24 4 1;
25  
26 __END__
« Everything/Adapter.pm ↑ Summary Everything/Adapter/Test.pm »