Branch Coverage

lib/Graphics/Fig/Parameters.pm
Criterion Covered Total %
branch 137 246 55.6


line true false branch
228 0 53 unless ($value =~ /^\s*($RE_REAL)/)
248 0 7 if ($value =~ /^\d+$/)
252 6 1 if (defined($temp = $AreaFills{$value}))
255 0 1 if ($value =~ /^shade(\d+)$/)
257 0 0 if ($val < 1 or $val > 19)
263 1 0 if ($value =~ /^tint(\d+)$/)
265 0 1 if ($val < 1 or $val > 19)
287 1 30 if ($value eq "none")
290 27 3 if ($value eq "forw" or $value eq "forward")
293 1 2 if ($value eq "back" or $value eq "backward")
296 2 0 if ($value eq "both")
316 0 7 if (ref $value eq "ARRAY" and scalar @{$value;} == 2)
319 7 0 if (defined($temp = $ArrowStyles{$value}))
338 0 5 if ($value eq "false" or $value eq 0)
341 5 0 if ($value eq "true" or $value eq 1)
361 0 1 if ($value =~ /^\d+$/)
365 1 0 if (defined($temp = $CapStyles{$value}))
387 0 42 if ($@)
407 0 12 if (not $value =~ /^$RE_INT$/ or $value < 0 or $value > 999)
426 0 0 if (ref $value ne "ARRAY")
430 0 0 if (ref $item ne "")
451 0 1 if (defined do { $context }->{'fontFlags'})
460 1 2 if ($flag eq 'rigid') { }
1 1 elsif ($flag eq 'special') { }
0 1 elsif ($flag eq 'postscript') { }
1 0 elsif ($flag eq 'hidden') { }
471 2 1 if ($op eq '-') { }
478 0 1 if ($value ne "")
499 0 0 unless (defined($temp = $FontNames{$value}))
519 0 0 if (not $value =~ /^\s*($RE_REAL)\s*$/ or $value <= 0)
540 0 5 unless ($value =~ /^\s*($RE_INT)/)
560 0 0 if ($value =~ /^\d+$/)
564 0 0 if (defined($temp = $JoinStyles{$value}))
585 0 650 unless ($value =~ s/^\s*($RE_REAL)//)
590 638 12 if ($value eq '') { }
12 0 elsif (defined($temp = $Units{$value})) { }
614 0 5 if ($value =~ /^\d+$/)
618 5 0 if (defined($temp = $LineStyles{$value}))
637 0 0 if ($value =~ /^Single$/i)
640 0 0 if ($value =~ /^Multiple$/i)
659 0 1 if ($value =~ /^Landscape$/i)
662 1 0 if ($value =~ /^Portrait$/i)
682 0 0 if ($value =~ /^Center$/i)
685 0 0 if ($value =~ /^Flush\s*left$/i)
705 0 0 if (defined $PaperSizes{$value})
724 0 280 if (ref $value ne "ARRAY" or scalar @{$value;} != 2 or not defined do { $value }->[0] or not defined do { $value }->[1])
747 0 82 if (ref $value ne "ARRAY")
752 19 63 if (scalar @{$value;} == 2 and ref do { $value }->[0] eq '' and ref do { $value }->[1] eq '') { }
777 0 0 if ($value =~ /^\s*($RE_REAL)\s*$/ and $value > 0)
798 7 0 if (ref $value eq 'ARRAY') { }
799 0 7 if (scalar @{$value;} != 2 or not defined($u = do { $value }->[0]) or not defined($v = do { $value }->[1]) or not $u =~ /^$RE_REAL/ or not $v =~ /^\s*$RE_REAL/)
805 0 0 if (not defined $value or !ref($value) eq "" or not $value =~ /$RE_REAL/)
828 1 13 if ($value eq "open-approximated")
831 1 12 if ($value eq "closed-approximated")
834 3 9 if ($value eq "open-interpolated")
837 1 8 if ($value eq "closed-interpolated")
840 7 1 if ($value eq "open-x")
843 1 0 if ($value eq "closed-x")
846 0 0 if ($value =~ /^\s*($RE_INT)/)
847 0 0 if ($value < 0 or $value > 5)
876 0 12 if ($n < 32 or $n == 127 or $n > 255)
898 0 1 if ($value eq "left")
901 1 0 if ($value eq "center")
904 0 0 if ($value eq "right")
907 0 0 if (not $value =~ /^$RE_INT$/ or $value < 0 or $value > 2)
927 0 0 if ($value == -1 or $value == -2)
933 0 0 if ($@)
955 1 1 if ($value =~ s/^\s*($RE_REAL)//)
959 0 2 unless (defined($temp = $Units{$value}))
975 157 74 if ($type eq '') { }
0 74 elsif ($type eq 'SCALAR') { }
74 0 elsif ($type eq 'ARRAY') { }
0 0 elsif ($type eq 'HASH') { }
0 0 elsif ($type eq 'CODE') { }
0 0 elsif ($type eq 'REF') { }
0 0 elsif ($type eq 'GLOB') { }
0 0 elsif ($type eq 'LVALUE') { }
1270 0 393 unless (defined $namedTemplate)
1281 200 193 if ($last >= 0 and ref $_[$last] eq "HASH")
1291 182 211 if ($signature ne "")
1293 0 182 unless (defined $positionalParameterNames)
1299 0 231 if (defined $namedParameters{$name})
1323 8855 835 unless (defined $aliases)
1328 561 9964 if (defined $tempValue)
1329 0 561 if (defined $pname)
1338 561 9129 if (defined $value)
1339 478 83 if (defined $convert) { }
1347 6583 2546 if (defined $defaults)
1348 2711 3872 if (defined($value = do { $defaults }->{$name}))
1353 3664 2754 if (defined $default)
1376 0 23 unless defined $offset
1377 0 23 unless ref $offset eq "ARRAY"
1397 18 6 unless (defined $center)
1400 0 24 unless defined $center
1401 0 24 unless defined $rotation
1429 8 0 unless (defined $center)
1432 0 8 unless defined $scale
1433 0 8 unless defined $center
1441 0 31 unless ref $point eq "ARRAY"
1459 29 71 unless (defined $x_min)
1466 33 38 if (do { $point }->[0] < $x_min)
1469 19 52 if (do { $point }->[1] < $y_min)
1472 14 57 if (do { $point }->[0] > $x_max)
1475 25 46 if (do { $point }->[1] > $y_max)
1497 45 93 if ($arrowMode & 1 << $i)
1500 43 2 unless (defined($temp = ${$parameters;}{"${prefix}ArrowStyle"}))
1504 44 1 unless (defined($temp = ${$parameters;}{"${prefix}ArrowThickness"}))
1508 44 1 unless (defined($temp = ${$parameters;}{"${prefix}ArrowWidth"}))
1512 44 1 unless (defined($temp = ${$parameters;}{"${prefix}ArrowHeight"}))
1539 13 17 if ($arrowMode & 1 << $i) { }
0 17 elsif (defined ${$object;}{"${prefix}Arrow"}) { }
1540 0 13 unless (defined($value = ${$object;}{"${prefix}Arrow"}))
1544 13 0 unless (defined($temp = ${$parameters;}{"${prefix}arrowStyle"}))
1547 0 13 if (($result = do { $value }->[0] <=> do { $temp }->[0]) != 0)
1550 0 13 if (($result = do { $value }->[1] <=> do { $temp }->[1]) != 0)
1553 13 0 unless (defined($temp = ${$parameters;}{"${prefix}arrowThickness"}))
1556 0 13 if (($result = do { $value }->[2] <=> $temp) != 0)
1559 13 0 unless (defined($temp = ${$parameters;}{"${prefix}arrowWidth"}))
1562 0 13 if (($result = do { $value }->[3] <=> $temp) != 0)
1565 13 0 unless (defined($temp = ${$parameters;}{"${prefix}arrowHeight"}))
1568 0 13 if (($result = do { $value }->[4] <=> $temp) != 0)
1592 42 70 if (defined($fArrow = do { $object }->{'fArrow'}))
1598 3 109 if (defined($bArrow = do { $object }->{'bArrow'}))