Info/PluginBase.pm

filter: Statementstmt 64.7% 11 / 17 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 66.6% 2 / 3 Podpod 0.0% 0 / 1 totaltotal 56.5% 13 / 23 SCAR 13.0
CC
3
Cov
58%
new
12.0
BEGIN
1.0
BEGIN
1.0
CRAP 3.7
« Info.pm ↑ Summary Info/Plugin/SearchQuery/google.pm »
1 package URI::Info::PluginBase;
2  
3 6 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 6 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 6 our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY
7 6 our $DATE = '2023-06-14'; # DATE
8 6 our $DIST = 'URI-Info'; # DIST
9 6 our $VERSION = '0.003'; # VERSION
10  
11 sub new {
12 0 ▶ my ($class, %args) = @_;
Subroutine new: not called CC=3 SCAR=24.8
Pod undocumented
13  
14 # check allowed arguments
15 0 my $meta = $class->meta;
16 0 my $conf = $meta->{conf};
17 0 for my $arg (keys %args) {
18 die "[URI::Info] Unrecognized plugin $class argument '$arg', please use one of ".join("/", sort keys %$conf)
19 0 ▶ unless exists $conf->{$arg};
Branch: 1 branch
BranchTrueFalseTotal
unless exists $conf->{$arg} 0 0 0
20 }
21  
22 0 bless \%args, $class;
23 }
24  
25 6 1;
26 # ABSTRACT: Base class for URI::Info::Plugin::*
27  
28 __END__
« Info.pm ↑ Summary Info/Plugin/SearchQuery/google.pm »