blib/lib/Metrics/Any/Adapter/Stderr.pm

filter: Statementstmt 90.0% 9 / 10 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 75.0% 3 / 4 Podpod 0.0% 0 / 1 totaltotal 80.0% 12 / 15 SCAR 0.0
CC
1
Cov
90%
new
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« blib/lib/Metrics/Any/Adapter/Tee.pm ↑ Summary blib/lib/Metrics/Any/Adapter/Null.pm »
1 # You may distribute under the terms of either the GNU General Public License
2 # or the Artistic License (the same terms as Perl itself)
3 #
4 # (C) Paul Evans, 2020 -- leonerd@leonerd.org.uk
5  
6 package Metrics::Any::Adapter::Stderr 0.08;
7  
8 1 ▶use v5.14;
Subroutine BEGIN: called CC=1 SCAR=0.0
9 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
10 1 ▶use base qw( Metrics::Any::Adapter::File );
Subroutine BEGIN: called CC=1 SCAR=0.0
11  
12 =head1 NAME
13  
14 C<Metrics::Any::Adapter::Stderr> - write metrics to C<STDERR>
15  
16 =head1 SYNOPSIS
17  
18 use Metrics::Any::Adapter 'Stderr';
19  
20 This L<Metrics::Any> adapter type writes observations of metric values to the
21 standard error stream. This may be helpful while debugging or otherwise
22 testing code that reports metrics.
23  
24 For example, by setting the C<METRICS_ANY_ADAPTER> environment variable to
25 configure the adapter, a metric log will be written to the terminal as a
26 side-effect of running a unit test:
27  
28 $ METRICS_ANY_ADAPTER=Stderr perl -Mblib t/01test.t
29  
30 =cut
31  
32 sub new
33 {
34 0 ▶ shift->SUPER::new( fh => \*STDERR, @_ );
Subroutine new: not called CC=1 SCAR=6.9
Pod undocumented
35 }
36  
37 =head1 AUTHOR
38  
39 Paul Evans <leonerd@leonerd.org.uk>
40  
41 =cut
42  
43 1 0x55AA;
« blib/lib/Metrics/Any/Adapter/Tee.pm ↑ Summary blib/lib/Metrics/Any/Adapter/Null.pm »