Branch Coverage

blib/lib/File/Slurper.pm
Criterion Covered Total %
branch 16 34 47.0


line true false branch
19 0 1 unless open my $fh, "<:unix", $filename
20 1 0 if (my $size = -s $fh) { }
24 0 1 unless defined($read = read($fh, ${$buf;}, $size - $pos, $pos))
41 0 6 if $crlf and $crlf eq "auto"
43 5 1 if ($encoding =~ /^utf-?8\b/i) { }
44 0 5 $crlf ? :
48 0 1 $crlf ? :
58 0 3 unless open my $fh, "<$layer", $filename
68 0 1 unless open my $fh, ">$layer", $filename
69 0 1 unless print $fh $_[1]
70 0 1 unless close $fh
76 0 0 unless open my $fh, ">:raw", $filename
77 0 0 unless print $fh $_[1]
78 0 0 unless close $fh
88 0 2 unless open my $fh, "<$layer", $filename
90 1 1 if $skip_chomp
99 0 1 unless opendir my $dir, $dirname