Branch Coverage

blib/lib/Music/RhythmSet/Voice.pm
Criterion Covered Total %
branch 88 88 100.0


line true false branch
30 9 2 if (exists $args->{'pattern'} and exists $args->{'ttl'})
31 2 7 if $args->{'ttl'} < 1
35 2 4 unless defined $args->{'pattern'} and ref $args->{'pattern'} eq "ARRAY" and @{$args->{'pattern'}}
56 22 14 if ($ttl <= 0)
59 2 20 unless defined $next and ref $next eq "CODE"
67 2 17 unless defined $param{'pattern'} and ref $param{'pattern'} eq "ARRAY" and @{$param{'pattern'}}
68 1 16 if $ttl < 1
108 6 4 if (defined $pat)
109 2 4 unless ref $pat eq "ARRAY" and @$pat
114 7 1 if (defined $ref)
115 1 6 unless ref $ref eq "ARRAY"
117 1 5 unless ref $ref->[0] eq "ARRAY"
128 2 9 unless defined $str and length $str
131 2 7 if ($param{'sep'}) { }
141 4 18 if $line =~ /^\s*(?:#|$)/u
145 14 4 if ($line =~ /^ (?\d{1,10}) $param{'sep'} (?.*?) $param{'sep'} (?[x.]{1,256}) $param{'sep'} (?\d{1,5}) \s*(?:[#].*)? $/ax) { }
173 2 7 unless defined $replay and ref $replay eq "ARRAY" and @$replay
188 3 7 if $ttl > $maxm
191 2 8 if ($param{'time'})
196 16 10 if ($x == 1) { }
205 6 4 if $maxm <= 0
215 2 12 unless defined $replay and ref $replay eq "ARRAY" and @$replay
235 5 7 length $id ? :
240 5 14 if $ttl > $maxm
251 26 20 if ($x == 1) { }
253 11 15 if (defined $open)
261 7 13 if (defined $open)
269 8 11 if (defined $open)
280 3 16 if ($delay and $onsets and $ttl > 1) { }
284 1 2 if ($param{'embig'}) { }
290 2 14 if ($param{'embig'}) { }
301 4 15 unless $onsets
304 9 10 if $maxm <= 0
316 3 9 if ($param{'sustain'} or $param{'notext'})
319 10 25 if ($param{'sustain'} and $events->[$i][0] eq 'note_off') { }
2 38 elsif ($param{'notext'} and $events->[$i][0] eq 'text_event') { }
325 1 11 if ($events->[$j][0] eq 'text_event' and $events->[$j][1] > 0) { }
9 2 elsif ($events->[$j][0] eq 'note_on') { }
329 4 5 if ($events->[$j][1] > 0)
336 1 2 if ++$j > $#$events
352 2 1 if $param{'notext'}
373 2 7 unless defined $replay and ref $replay eq "ARRAY" and @$replay
390 3 9 if $ttl > $maxm
397 5 7 if $maxm <= 0