Business/CyberSource/Role/Traceable.pm

filter: Statementstmt 90.4% 19 / 21 Branchbran 50.0% 1 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 71.4% 5 / 7 Podpod 100% 2 / 2 totaltotal 84.3% 27 / 32 CC 2 SCAR 4.2
CC
2
Cov
87%
__ANON__
2.1
trace
2.0
has_trace
2.0
CRAP 1.5
« Business/CyberSource/Factory/Response.pm ↑ Summary Business/CyberSource/Response/Role/Base.pm »
1 package Business::CyberSource::Role::Traceable;
2 26 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 26 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 26 our $VERSION = '0.010008'; # VERSION
6  
7 26 ▶use Moose::Role;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 26 ▶use MooseX::SetOnce;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 26 our @CARP_NOT = ( 'Class::MOP::Method::Wrapped', __PACKAGE__ );
11  
12 26 has http_trace => (
13 isa => 'XML::Compile::SOAP::Trace',
14 predicate => 'has_http_trace',
15 traits => [ 'SetOnce' ],
16 is => 'rw',
17 writer => '_http_trace',
18 );
19  
20 0 ▶sub trace { return $_[0]->http_trace } ## no critic ( RequireArgUnpacking RequireFinalReturn )
Subroutine trace: not called CC=1 SCAR=6.9
Pod documented
21 0 ▶sub has_trace { return $_[0]->has_http_trace } ## no critic ( RequireArgUnpacking RequireFinalReturn )
Subroutine has_trace: not called CC=1 SCAR=6.9
Pod documented
22  
23 2 ▶before [qw( trace has_trace ) ] => sub {
Subroutine __ANON__: called CC=2 SCAR=7.2
24 2 my $self = shift;
25 2 ▶ warnings::warnif('deprecated', # this is due to Moose::Exception conflict
Branch: 1 branch
BranchTrueFalseTotal
unless $self->isa("Moose::Exception") 0 2 2
26 '`trace` is deprecated call `http_trace` instead'
27 ) unless $self->isa('Moose::Exception');
28 26 };
29  
30 26 1;
31 # ABSTRACT: provides http_trace
32  
33 __END__
« Business/CyberSource/Factory/Response.pm ↑ Summary Business/CyberSource/Response/Role/Base.pm »