blib/lib/Moose/Exception/MethodExpectsMoreArgs.pm

filter: Statementstmt 100% 11 / 11 Branchbran 100% 2 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 2 / 2 Podpod n/a totaltotal 100% 15 / 15 CC 2 SCAR 5.1
CC
2
Cov
100%
_build_message
2.0
BEGIN
1.0
CRAP 1.7
« blib/lib/Moose/Exception/EnumValuesMustBeString.pm ↑ Summary blib/lib/Moose/Exception/OverrideConflictInComposition.pm »
1 package Moose::Exception::MethodExpectsMoreArgs;
2 5 our $VERSION = '2.4001';
3  
4 5 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 5 extends 'Moose::Exception';
6  
7 5 has 'method_name' => (
8 is => 'ro',
9 isa => 'Str',
10 required => 1
11 );
12  
13 5 has 'minimum_args' => (
14 is => 'ro',
15 isa => 'Int',
16 required => 1
17 );
18  
19 148 ▶sub _build_message {
Subroutine _build_message: called CC=2 SCAR=6.9
20 148 my $self = shift;
21 148 ▶ "Cannot call ".$self->method_name." without at least ".$self->minimum_args." argument".($self->minimum_args == 1 ? '' : 's');
Branch: 1 branch
BranchTrueFalseTotal
$self->minimum_args == 1 ? : 145 3 148
22 }
23  
24 5 __PACKAGE__->meta->make_immutable;
25 5 1;
« blib/lib/Moose/Exception/EnumValuesMustBeString.pm ↑ Summary blib/lib/Moose/Exception/OverrideConflictInComposition.pm »