Rssfilter/Match/BbcSports.pm

filter: Statementstmt 100% 17 / 17 Branchbran 100% 4 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 5 / 5 Podpod n/a totaltotal 100% 26 / 26 CC 3 SCAR 6.2
CC
3
Cov
100%
match
3.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.9
« Rssfilter/Cmd/runfromconfig.pm ↑ Summary Rssfilter/FromYaml.pm »
1 # ABSTRACT: match a BBC sport RSS item
2  
3 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6  
7 package App::Rssfilter::Match::BbcSports;
8 1 $App::Rssfilter::Match::BbcSports::VERSION = '0.08'; # TRIAL
9 1 ▶use Method::Signatures;
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11  
12 1 ▶func match ( $item ) {
Subroutine BEGIN: called CC=1 SCAR=0.0
Subroutine match: called CC=3 SCAR=11.0
Branch: 2 branches
BranchTrueFalseTotal
unless scalar @_ > 0 1 5 6
if scalar @_ > 1 1 4 5
13 4 return $item->at('guid')->text =~ qr{ www [.] bbc [.] co [.] uk / sport [1]? / }xms;
14 }
15  
16 1 1;
17  
18 __END__
« Rssfilter/Cmd/runfromconfig.pm ↑ Summary Rssfilter/FromYaml.pm »