Branch Coverage

blib/lib/FileHandle/Unget.pm
Criterion Covered Total %
branch 53 90 58.8


line true false branch
28 0 161 unless my $class = shift()
38 1495 4048 unless defined &$fullname
39 2415 1633 if defined &{'FileHandle::Unget' . "::$method";}
40 92 1541 if $method eq 'import'
42 1541 0 unless ($$seen{$method})
50 180 2 if (ref $self eq 'FileHandle::Unget') { }
89 12 36 if (defined $_[0] and defined CORE::fileno $_[0]) { }
96 0 36 unless defined $self
129 0 1 unless defined $self
173 1 2 if @_
183 3 0 if (@_)
188 0 3 unless exists tied(*$self)->{'input_record_separator'}
233 0 59 unless exists $tie_mapping{$name}
243 92 51 if (defined &$sub) { }
292 1 1 if $$self{'eof_called'}
304 0 2 if (@_) { }
342 4 57 if (wantarray) { }
369 3 54 if exists $$self{'input_record_separator'}
373 9 48 if (defined $input_record_separator and $$self{'filehandle_unget_buffer'} =~ /(.*?$input_record_separator)/) { }
5 43 elsif (not defined $input_record_separator) { }
393 0 5 if @other_lines and not defined $other_lines[0]
395 0 5 if ($line eq '' and not @other_lines) { }
410 2 41 if ($line eq '' and not defined $templine) { }
41 0 elsif (defined $templine) { }
442 0 4 if exists $$self{'input_record_separator'}
446 4 0 if (defined $input_record_separator) { }
453 3 1 if (@other_lines) { }
455 3 0 if (defined $other_lines[0])
462 0 1 if ($$self{'filehandle_unget_buffer'} ne '')
481 0 0 if ($buffer_lines[0] eq '' and not defined $other_lines[0]) { }
515 0 0 if ($$self{'filehandle_unget_buffer'} ne '') { }
551 3 7 if ($$self{'filehandle_unget_buffer'} ne '') { }
559 0 3 if (length $read_string < $length)
565 0 3 if (defined $offset) { }
567 0 0 unless defined $$scalar
579 3 4 if (defined $_[2]) { }
611 0 1 if ($whence != 0 and $whence != 1 and $whence != 2)
620 3 0 if (CORE::seek $$self{'fh'}, $position, $whence) { }
629 0 0 if $whence == 0
630 0 0 if $whence == 1
631 0 0 if $whence == 2
633 0 0 if ($absolute_position <= CORE::tell $$self{'fh'}) { }
635 0 0 if ($absolute_position >= $self->tell) { }
677 0 11 if ($file_position == -1)
707 0 4 if ($$self{'filehandle_unget_buffer'} ne '') { }