Branch Coverage

blib/lib/Date/Holidays/GB.pm
Criterion Covered Total %
branch 40 46 86.9


line true false branch
43 0 1641 unless $date and $region and $name
54 352 950 if keys %{$holiday;} == @{["EAW","NIR","SCT"];}
62 4 3 $_[0] =~ /\D/ ? :
67 0 7 unless (exists $args{'year'} and defined $args{'year'})
72 0 7 unless ($args{'year'} =~ /^\d{4}$/)
77 4 3 unless $args{'regions'}
0 7 unless my(@region_codes) = @{["EAW","NIR","SCT"] unless $args{'regions'};}
83 14 51 unless my $string = _holiday($holiday, \@region_codes)
86 13 38 if ($args{'ymd'}) { }
99 0 1 $_[0] =~ /\D/ ? :
110 18 6 $_[0] =~ /[^0-9-]/ ? :
117 6 18 if ($args{'date'}) { }
124 0 24 unless $y and $m and $d
130 6 18 unless $args{'regions'}
3 21 unless my(@region_codes) = @{["EAW","NIR","SCT"] unless $args{'regions'};}
134 8 13 unless my $holiday = $holidays{$y}{$date}
145 2 2 unless (@regions)
156 14 22 unless $date gt $today
161 13 30 unless my $name = $holiday->{$region}
166 2 20 if $next_holidays{'all'} or keys %next_holidays == @{["EAW","NIR","SCT"];}
176 35 43 if $holiday->{'all'}
184 42 29 unless $holiday->{$region}
189 18 25 unless %names