NoOp/Tracer.pm

filter: Statementstmt 68.1% 15 / 22 Branchbran 50.0% 1 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 41.6% 5 / 12 Podpod 0.0% 0 / 7 totaltotal 48.8% 21 / 43 CC 2 SCAR 5.3
CC
2
Cov
67%
BEGIN
2.0
new
2.0
get_scope_manager
2.0
CRAP 1.7
« NoOp/ScopeManager.pm ↑ Summary NoOp.pm »
1 package OpenTracing::Implementation::NoOp::Tracer;
2  
3 =head1 NAME
4  
5 OpenTracing::Implementation::NoOp::Tracer - NoOp, so code won't break!
6  
7 =head1 DESCRIPTION
8  
9 Objects of this class implement the required methods of the
10 L<OpenTracing::Interface::Tracer>, to be compliant during testing and allow
11 applications to continue working without having to catch exceptions all the
12 time.
13  
14 None of the methods will do anything useful.
15  
16 =cut
17  
18 2 our $VERSION = 'v0.72.1';
19  
20  
21  
22 2 ▶use OpenTracing::Implementation::NoOp::Scope;
Subroutine BEGIN: called CC=1 SCAR=0.0
23 2 ▶use OpenTracing::Implementation::NoOp::ScopeManager;
Subroutine BEGIN: called CC=1 SCAR=0.0
24 2 ▶use OpenTracing::Implementation::NoOp::Span;
Subroutine BEGIN: called CC=1 SCAR=0.0
25  
26  
27 0 ▶sub new { bless {} }
Subroutine new: not called CC=1 SCAR=6.9
Pod undocumented
28  
29  
30 0 ▶sub get_scope_manager {
Subroutine get_scope_manager: not called CC=1 SCAR=6.9
Pod undocumented
31 0 OpenTracing::Implementation::NoOp::ScopeManager->new( )
32 }
33  
34 0 ▶sub get_active_span {
Subroutine get_active_span: not called CC=1 SCAR=6.9
Pod undocumented
35 0 OpenTracing::Implementation::NoOp::Span->new( )
36 }
37  
38 0 ▶sub start_active_span {
Subroutine start_active_span: not called CC=1 SCAR=6.9
Pod undocumented
39 0 OpenTracing::Implementation::NoOp::Scope->new( )
40 }
41  
42 0 ▶sub start_span {
Subroutine start_span: not called CC=1 SCAR=6.9
Pod undocumented
43 0 OpenTracing::Implementation::NoOp::Span->new( )
44 }
45  
46 0 ▶sub inject_context { $_[1] } # carrier
Subroutine inject_context: not called CC=1 SCAR=6.9
Pod undocumented
47  
48 0 ▶sub extract_context { undef }
Subroutine extract_context: not called CC=1 SCAR=6.9
Pod undocumented
49  
50  
51  
52 2 ▶BEGIN {
Subroutine BEGIN: called CC=2 SCAR=7.0
53 2 ▶ use Role::Tiny::With;
Subroutine BEGIN: called CC=1 SCAR=0.0
54 with 'OpenTracing::Interface::Tracer'
55 2 ▶ if $ENV{OPENTRACING_INTERFACE};
Branch: 1 branch
BranchTrueFalseTotal
if $ENV{"OPENTRACING_INTERFACE"} 0 2 2
56 } # check at compile time, perl -c will work
57  
58  
59  
60 2 1;
« NoOp/ScopeManager.pm ↑ Summary NoOp.pm »