Branch Coverage

blib/lib/IO/Zlib.pm
Criterion Covered Total %
branch 56 78 71.7


line true false branch
307 0 9 $@ || $Compress::Zlib::VERSION < 2.0 ? :
337 0 0 unless $has_Compress_Zlib
346 3 5 if ($_[0] eq ':gzip_external') { }
2 3 elsif ($_[0] eq ':gzip_read_open') { }
2 1 elsif ($_[0] eq ':gzip_write_open') { }
350 2 1 if (@_) { }
363 2 0 if (@_) { }
367 1 1 unless $gzip_read_open =~ /^.+%s.+\|\s*$/
379 2 0 if (@_) { }
383 1 1 unless $gzip_write_open =~ /^\s*\|.+%s.*$/
404 3 10 if ($gzip_external or not $has_Compress_Zlib || defined $gzip_external) { }
10 0 elsif ($has_Compress_Zlib) { }
440 8 8 if (@_)
442 1 4 if (_import($import, @_))
458 18 4 @args ? :
471 0 22 unless defined $filename
475 17 4 defined $self->{'file'} ? :
482 0 15 unless defined $self->{'file'}
488 15 0 $status == 0 ? :
498 0 13 unless defined $nbytes
500 11 2 unless defined $$bufref
504 0 13 if $bytesread < 0
515 1 6 if $self->{'file'}->gzreadline($line) <= 0
517 5 1 unless wantarray
536 0 7 unless $offset + $length <= length $buf
558 1 19 unless $aliased
564 15 4 tied ${$self;} ? :
578 1 1 unless wantarray
607 3 2 if ($mode =~ /r/) { }
1 1 elsif ($mode =~ /w/) { }
616 2 1 if (-e $filename and open $fh, $filename) { }
623 2 0 if ($rdb == 2 and $sig eq "\37\213")
627 2 0 if (open $fh, $ropen) { }
639 0 0 unless seek $fh, 0, 0
651 0 1 $mode =~ /([1-9])/ ? :
661 1 0 if (open $fh, $wopen) { }
693 2 0 defined $nread ? :
706 1 0 defined $nwrote ? :
717 0 0 defined $$bufref ? :