Branch Coverage

blib/lib/Directory/Organize.pm
Criterion Covered Total %
branch 57 78 73.0


line true false branch
23 6 0 unless (exists $self->{'descriptions'})
26 6 0 wantarray ? :
35 1 2 if (-d $dirprefix)
44 12 0 if ($1) { }
46 0 12 unless -d $dir or mkdir $dir, 511
50 0 0 unless $dir
54 3 0 if ($descr and open my $PROJ, '>', $project)
65 0 1 if ($pattern and defined $self->{'pattern'} and $self->{'pattern'} eq $pattern)
70 0 1 unless ($pattern or defined $self->{'pattern'})
74 1 1 if (not $pattern) { }
84 4 0 if (defined $year and $op =~ /^[=<>]$/) { }
87 4 0 if defined $month
88 3 1 if defined $day
92 0 0 if ($self->{'tc'})
102 3 4 if (defined $tyear)
111 1 3 if (defined $tmonth) { }
1 2 elsif (defined $tday) { }
135 8 12 if (defined $day) { }
8 4 elsif (defined $month) { }
136 7 1 if (defined $tc->{'day'}) { }
1 0 elsif (defined $tc->{'month'}) { }
150 6 2 if (defined $tc->{'day'}) { }
2 0 elsif (defined $tc->{'month'}) { }
153 2 4 if '>' eq $tc->{'op'}
154 4 2 if '<' eq $tc->{'op'}
166 4 0 if (defined $tc->{'month'}) { }
169 1 3 if '>' eq $tc->{'op'}
170 2 2 if '<' eq $tc->{'op'}
178 6 4 '>' eq $tc->{'op'} ? :
10 10 '<' eq $tc->{'op'} ? :
189 6 0 if (opendir my $BASEDIR, $base)
201 0 6 if $self->{'tc'} and $self->_not_in_tc($year)
202 6 0 if (opendir my $YEARDIR, "$base/$year")
215 2 10 if $self->{'tc'} and $self->_not_in_tc($year, $month)
216 10 0 if (opendir my $MONTHDIR, "$base/$year/$month")
218 14 20 if /^ # match names that start \d{2} # with two digits /x
230 1 13 if $self->{'tc'} and $self->_not_in_tc($year, $month, $day)
233 13 0 if (-f "$base/$path/.project" and open my $PROJECT, '<', "$base/$path/.project")
239 2 11 if ($self->{'pattern'} and not $desc =~ /$self->{'pattern'}/i)