Mapper/Persona/Generic.pm

filter: Statementstmt 72.2% 13 / 18 Branchbran 0.0% 0 / 2 Conditioncond 0.0% 0 / 2 MC/DCmcdc 0.0% 0 / 1 Subroutinesub 80.0% 4 / 5 Podpod 100% 1 / 1 totaltotal 62.0% 18 / 29 CC 4 SCAR 12.9
CC
4
Cov
59%
feeds
6.0
_init
4.7
BEGIN
1.0
CRAP 3.6
« Mapper.pm ↑ Summary Mapper/Persona/Website.pm »
1 package Net::Social::Mapper::Persona::Generic;
2  
3 9 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 9 ▶use base qw(Net::Social::Mapper::Persona);
Subroutine BEGIN: called CC=1 SCAR=0.0
5 9 ▶use Feed::Find;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 =head1 NAME
8  
9 Net::Social::Mapper::Persona::Generic - the persona for a generic service
10  
11 =head2 SYNOPSIS
12  
13 See C<Net::Social::Mapper>
14  
15 =cut
16  
17 5 ▶sub _init {
Subroutine _init: called CC=3 SCAR=15.4
18 5 my $self = shift;
19 5 my $sitemap = $self->mapper->sitemap;
20 5 ▶ my $profile = $sitemap->profile($self->{service}, $self->{user}) || return;
Condition0%0/2
$sitemap->profile($self->{'service'}, $self->{'user'}) || (return)
l!l
00
MC/DC0%0/1
$sitemap->profile($self->{'service'}, $self->{'user'}) || (return)
$sitemap->profile($self->{'service'}, $self->{'user'})
Truth table0%0/2
A
A= $sitemap->profile($self->{'service'}, $self->{'user'})
Aresult
11
00
21 0 $self->{$_} = $profile->{$_} for keys %$profile;
22 0 return $self;
23 }
24  
25 =head2 feeds
26  
27 Get the feeds for this website.
28  
29 =cut
30 0 ▶sub feeds {
Subroutine feeds: not called CC=2 SCAR=17.9
Pod documented
31 0 my $self = shift;
32 0 ▶ $self->{feeds} = [ $self->mapper->_get_feeds($self->{homepage}) ] unless defined $self->{feeds};
Branch: 1 branch
BranchTrueFalseTotal
unless defined $self->{"feeds"} 0 0 0
33 0 return $self->SUPER::feeds;
34 }
35  
36 9 1;
37  
« Mapper.pm ↑ Summary Mapper/Persona/Website.pm »