test-data/scripts/lib/Local/PkgNoisy.pm

filter: Statementstmt 80.0% 8 / 10 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 75.0% 3 / 4 Podpod 0.0% 0 / 1 totaltotal 73.3% 11 / 15 CC 1 SCAR 2.2
CC
1
Cov
80%
noisy
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« test-data/lib/Local/NoUnused.pm ↑ Summary script/perlvars »
1 package Local::PkgNoisy;
2  
3 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 # A file with a package statement is analyzed directly. Its compile-time code
7 # still runs when Test::Vars requires it; that output (and any stray TAP) must
8 # not leak through perlvars, while the genuine finding below is still reported.
9 2 ▶BEGIN { print STDERR "compile-time noise from a packaged file\n"; }
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 0 ▶sub noisy {
Subroutine noisy: not called CC=1 SCAR=6.9
Pod undocumented
12 0 my $unused_pkg_var = 42;
13 0 return;
14 }
15  
16 2 1;
« test-data/lib/Local/NoUnused.pm ↑ Summary script/perlvars »