lib/Perl/Critic/Exception/Configuration/Option/Global/ExtraParameter.pm

filter: Statementstmt 95.8% 23 / 24 Branchbran 50.0% 1 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 6 / 6 Podpod 100% 1 / 1 totaltotal 93.9% 31 / 33 CC 2 SCAR 2.6
CC
2
Cov
92%
full_message
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.3
« lib/Perl/Critic/Policy/ControlStructures/ProhibitCStyleForLoops.pm ↑ Summary lib/Perl/Critic/Exception/Configuration/Option/Policy/ExtraParameter.pm »
1 package Perl::Critic::Exception::Configuration::Option::Global::ExtraParameter;
2  
3 40 ▶use 5.010001;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 40 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 40 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 40 ▶use Readonly;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 40 our $VERSION = '1.156';
10  
11 #-----------------------------------------------------------------------------
12  
13 40 ▶use Exception::Class (
Subroutine BEGIN: called CC=1 SCAR=0.0
14 40 'Perl::Critic::Exception::Configuration::Option::Global::ExtraParameter' => {
15 isa => 'Perl::Critic::Exception::Configuration::Option::Global',
16 description => 'The configuration referred to a non-existent global option.',
17 alias => 'throw_extra_global',
18 },
19 40 );
20  
21 #-----------------------------------------------------------------------------
22  
23 40 Readonly::Array our @EXPORT_OK => qw< throw_extra_global >;
24  
25 #-----------------------------------------------------------------------------
26  
27 4 ▶sub full_message {
Subroutine full_message: called CC=2 SCAR=7.1
Pod documented
28 4 my ( $self ) = @_;
29  
30 4 my $source = $self->source();
31 4 ▶ if ($source) {
Branch: 1 branch
BranchTrueFalseTotal
if ($source) { } 0 4 4
32 0 $source = qq{ (found in "$source")};
33 }
34 else {
35 4 $source = q{};
36 }
37  
38 4 my $option_name = $self->option_name();
39  
40 4 return qq{"$option_name" is not a supported option$source.};
41 }
42  
43  
44 40 1;
45  
46 __END__
« lib/Perl/Critic/Policy/ControlStructures/ProhibitCStyleForLoops.pm ↑ Summary lib/Perl/Critic/Exception/Configuration/Option/Policy/ExtraParameter.pm »