File Coverage

blib/lib/Acme/PriPara.pm
Criterion Covered Total %
statement 25 25 100.0
branch 1 2 50.0
condition n/a
subroutine 7 7 100.0
pod 0 2 0.0
total 33 36 91.6


line stmt bran cond sub pod time code
1             package Acme::PriPara;
2 3     3   1647 use 5.008001;
  3         7  
  3         102  
3 3     3   11 use strict;
  3         4  
  3         82  
4 3     3   21 use warnings;
  3         3  
  3         70  
5 3     3   1689 use utf8;
  3         24  
  3         11  
6              
7             our $VERSION = "0.02";
8              
9 3     3   1696 use Readonly;
  3         7521  
  3         941  
10              
11             Readonly our $Laara_and_Mirei => [
12             'ManakaLaara',
13             'MinamiMirei',
14             ];
15             Readonly our $SoLaMi_Smile => [
16             @$Laara_and_Mirei,
17             'HojoSophy',
18             ];
19              
20             Readonly our $Dorothy_and_Reona => [
21             'DorothyWest',
22             'ReonaWest',
23             ];
24             Readonly our $Dressing_Pafé => [
25             'TodoSion',
26             @$Dorothy_and_Reona,
27             ];
28              
29             Readonly our $MainMembers => [
30             @$SoLaMi_Smile,
31             @$Dressing_Pafé,
32             ];
33              
34             sub main_members {
35 1     1 0 1240 my $self = shift;
36 1         4 return $self->members_of($MainMembers);
37             }
38              
39             sub members_of {
40 5     5 0 9766 my ($self, $team) = @_;
41 5         24 my @members;
42 5         7 for my $member_name (@{ $team }) {
  5         10  
43 16         29 my $pkg = "Acme::PriPara::MainMembers::$member_name";
44 16 50       923 if (eval "require $pkg;1;") {
45 16         189 push @members, $pkg->new;
46             }
47             }
48 5         18 return @members;
49             }
50              
51             1;
52             __END__