Branch Coverage

blib/lib/Number/Fraction.pm
Criterion Covered Total %
branch 63 104 60.5


line true false branch
229 10 5 if $args{':constants'}
461 2 208 if $self->{'den'} == 0
474 5 203 if ($self->{'den'} < 0)
491 23 97 if $self->{'den'} == 1
506 0 0 if $self->{'den'} == 1
508 0 0 $self->{'num'} * $self->{'den'} < 0 ? :
511 0 0 $int ? :
587 0 0 unless @denominators
591 0 0 if $near->{'den'} == 1
593 0 0 $near->{'num'} * $near->{'den'} < 0 ? :
597 0 0 unless ($frc)
633 10 2 if (ref $r) { }
634 9 1 if (UNIVERSAL::isa($r, ref $l)) { }
641 1 1 if ($r =~ /^[-+]?\d+$/) { }
662 10 2 if (ref $r) { }
663 9 1 if (UNIVERSAL::isa($r, ref $l)) { }
670 1 1 if ($r =~ /^[-+]?\d+$/) { }
691 11 4 if (ref $r) { }
692 10 1 if (UNIVERSAL::isa($r, ref $l)) { }
699 2 2 if ($r =~ /^[-+]?\d+$/) { }
701 1 1 $rev ? :
703 1 1 $rev ? :
721 12 4 if (ref $r) { }
722 11 1 if (UNIVERSAL::isa($r, ref $l)) { }
723 1 10 if $r->{'num'} == 0
730 2 2 if ($r =~ /^[-+]?\d+$/) { }
732 1 1 $rev ? :
734 1 1 $rev ? :
753 2 8 if ($rev)
757 2 0 unless $@
761 5 3 if (UNIVERSAL::isa($r, ref $l)) { }
3 0 elsif ($r =~ /^[-+]?\d+$/) { }
762 1 4 if ($r->{'den'} == 1) { }
773 0 0 UNIVERSAL::isa($r, ref $l) ? :
778 0 0 unless $@
780 0 0 if $@
782 0 0 unless $@
835 18 41 if (UNIVERSAL::isa($r, ref $l)) { }
842 59 0 unless $rev
849 20 41 if (UNIVERSAL::isa($r, ref $l)) { }
856 61 0 unless $rev
861 0 55 if _frac_lt(@_)
862 14 41 if _frac_gt(@_)
875 0 0 if $self->{'den'} == 1
877 0 0 unless @denominators
882 0 0 if (CORE::abs($self->{'num'} * $frc->{'den'} - $frc->{'num'} * $self->{'den'}) * $den - CORE::abs($self->{'num'} * $den - $num * $self->{'den'}) * $frc->{'den'} > 0)
897 168 40 if $y > $x
899 9 199 if $x == $y
936 0 0 if ($_[0] =~ m[^(?-?)(?\d+)/(?\d+)$])
939 0 0 $+{'sign'} ? :
941 0 0 if ($_[0] =~ m[^(?-?)(?\d+)$MIXED_SEP(?\d+)/(?\d+)$])
946 0 0 if ($_[0] =~ /^(?-?)(?\d+)$/)