Branch Coverage

blib/lib/PAGI/Server/AsyncFile.pm
Criterion Covered Total %
branch 20 54 37.0


line true false branch
67 28 0 builtin::blessed($loop) ? :
69 3 25 unless ($_function_pools{$loop_id})
91 0 0 if ($op eq 'read_file') { }
0 0 elsif ($op eq 'read_chunk') { }
0 0 elsif ($op eq 'write_file') { }
0 0 elsif ($op eq 'append_file') { }
0 0 elsif ($op eq 'file_size') { }
0 0 elsif ($op eq 'file_exists') { }
93 0 0 unless open my $fh, "<:raw", $path
101 0 0 unless open my $fh, "<:raw", $path
102 0 0 if $offset
109 0 0 unless open my $fh, ">:raw", $path
116 0 0 unless open my $fh, ">>:raw", $path
127 0 0 -f $path ? :
158 1 10 unless -f $path
159 0 10 unless -r $path
213 0 7 unless -f $path
214 0 7 unless -r $path
227 4 3 defined $max_length ? :
230 0 7 if $end_pos > $file_size
236 5 12 if ($offset + $to_read > $end_pos)
240 0 17 if $to_read <= 0
246 0 17 unless $bytes_read
250 4 13 if (builtin::blessed($result) and $result->can("get"))
362 1 0 if ($loop) { }
363 1 0 builtin::blessed($loop) ? :
364 1 0 if (my $function = delete $_function_pools{$loop_id})