Branch Coverage

lib/XML/SAX/SVGTransformer.pm
Criterion Covered Total %
branch 66 106 62.2


line true false branch
26 3 10 if ($name eq 'svg' and not $self->_seen($name)) { }
3 14 elsif ($self->_stash('svg') and not $self->_stash('grouped')) { }
32 1 2 if ($name eq 'g' and (_attr($elem, 'id') || '') eq $self->_group_id) { }
35 0 2 $svg->{'Prefix'} ? :
59 1 2 unless $self->_stash("added_group")
67 1 0 if ($self->{'_stash'})
79 3 10 if ($name eq "svg")
80 2 1 if ($self->_seen($name) == 1 and $self->_stash("added_group") and $prev eq "g")
82 0 2 $elem->{'Prefix'} ? :
95 0 0 unless +(shift())->{'_info'}
110 2 1 if $self->{'_comment'}
112 3 0 if ($svg_viewbox) { }
155 3 3 if ($transform)
160 3 1 if ($name eq 'rotate') { }
0 1 elsif ($name eq 'flipx') { }
0 1 elsif ($name eq 'flipy') { }
0 1 elsif ($name eq 'matrix') { }
161 1 2 if (@ops and $ops[-1][0] eq 'rotate') { }
169 0 0 if (@ops and $ops[-1][0] eq 'matrix') { }
176 0 0 if (@ops and $ops[-1][0] eq 'matrix') { }
188 0 0 if (@ops and $ops[-1] eq 'matrix') { }
201 3 6 if ($name eq 'rotate') { }
0 6 elsif ($name eq 'matrix') { }
6 0 elsif ($name eq 'scale') { }
212 0 3 if ($matrix->equal($IdMatrix))
234 2 6 if ($name eq 'rotate') { }
0 6 elsif ($name eq 'matrix') { }
3 3 elsif ($name eq 'scale') { }
3 0 elsif ($name eq 'translate') { }
235 0 2 unless $args[0]
238 0 0 if $args[0]->equal($IdMatrix)
242 2 1 if $args[0] == 1 and $args[1] == 1
245 0 0 unless $args[0] or $args[1]
253 3 14 unless my $number = shift()
257 0 14 unless $number
262 0 7 unless defined $value
283 5 1 if ($set->{'min_x'} and $set->{'min_x'} < 0)
288 1 5 if ($set->{'min_y'} and $set->{'min_y'} < 0)
326 0 3 if ($x and $y) { }
1 2 elsif ($x) { }
0 2 elsif ($y) { }
327 0 0 if ($set->{'max_x'})
330 0 0 if ($set->{'max_y'})
334 1 0 if ($set->{'max_x'})
339 0 0 if ($set->{'max_y'})
355 0 15 if ($name ne $popped)
369 0 5 if ($self->{'SessionId'}) { }
379 11 22 if (@_)
388 12 18 if (@_) { }
390 12 0 if (defined $value and $value ne '') { }
391 4 8 unless (exists $elem->{'Attributes'}{"{}$name"}{'Name'})
400 0 18 unless exists $elem->{'Attributes'}
401 9 9 unless exists $elem->{'Attributes'}{"{}$name"}