Branch Coverage

blib/lib/IPC/Run/IO.pm
Criterion Covered Total %
branch 79 118 66.9


line true false branch
78 0 126 if (&Win32_MODE())
79 0 0 unless eval "use IPC::Run::Win32Helper; require IPC::Run::Win32IO; 1" or $@ and die
106 0 7 unless $type =~ /^(?:<>?)$/
111 7 0 if (not ref $external) { }
0 0 elsif (ref $external eq 'GLOB' or UNIVERSAL::isa($external, 'IO::Handle')) { }
131 0 2618 if &Win32_MODE() and $class eq "IPC::Run::IO"
149 1709 909 if ($self->op =~ />/) { }
150 0 1709 if &_empty($internal)
152 98 1611 if (UNIVERSAL::isa($self->{'DEST'}, "CODE"))
173 0 909 if &_empty($internal)
175 68 841 if (UNIVERSAL::isa($internal, 'CODE')) { }
558 283 elsif (UNIVERSAL::isa($internal, 'SCALAR')) { }
180 0 82 if length $$out_ref
183 0 82 if $self->{'SOURCE_EMPTY'}
186 46 36 unless (defined $in)
190 7 29 unless length $in
202 0 1780 if length $$out_ref
207 485 929 $self->{'HARNESS'}{'auto_close_ins'} ? :
1414 366 if &IPC::Run::_empty(${$$self{"SOURCE"};}) or $self->{'SOURCE_EMPTY'}
211 109 257 if $self->{'HARNESS'}{'clear_ins'}
233 0 4 if @_
249 1 1 if $self->mode =~ /r/ and ref $self->{'DEST'} eq "SCALAR"
251 2 0 if defined $self->filename
254 0 2 if (not $self->{'FILTERS'}) { }
264 1 1 if $self->{'DEST'} and ref $self->{'DEST'} eq "SCALAR"
289 0 2 unless defined $self->{'FILENAME'}
290 2 0 unless $self->{'HANDLE'}
292 0 2 if &_debugging_data()
297 0 2 unless sysopen $self->{'HANDLE'}, $self->filename, $open_flags{$self->op}
314 640 1447 if ($self->dir eq '<') { }
316 28 612 if ($parent_handle)
317 0 28 unless CORE::open $parent_handle, ">&=$self->{'FD'}"
323 52 1395 if ($parent_handle)
324 0 52 unless CORE::open $parent_handle, "<&=$self->{'FD'}"
335 0 2087 if defined $self->{'FILENAME'}
342 640 1447 $self->dir eq '<' ? :
360 2 1831 if (defined $self->{'HANDLE'}) { }
366 0 0 defined $self->{'FILENAME'} ? :
0 2 unless CORE::close $self->{'HANDLE'}
395 0 0 defined $self->{'FILENAME'} ? :
0 4 unless defined $fd
426 0 10 if @_
429 5 5 $self->{'TYPE'} =~ /
2 8 $self->{'TYPE'} =~ /<<|>>/ ? :
442 0 2620 if @_
457 2618 0 if @_
471 0 9245 if @_
490 0 2734 unless UNIVERSAL::isa($self, "IPC::Run::IO")
494 1306 1428 if $self->{'DEST'} and ref $self->{'DEST'} eq "SCALAR"
496 1702 1032 unless $self->{'FILTERS'} and @{$self->{'FILTERS'};}
518 5071 32 if (defined $self->{'FD'})
520 1057 4014 if ($d eq '<') { }
4014 0 elsif ($d eq '>') { }
521 888 169 if (vec $harness->{'WOUT'}, $self->{'FD'}, 1)
522 0 888 if &_debugging_details()
528 2557 1457 if (vec $harness->{'ROUT'}, $self->{'FD'}, 1)
529 0 2557 if &_debugging_details()
553 0 5510 if (($@ || '') =~ /$IPC::Run::_EAGAIN/ and $redos++ < 200)
560 0 5510 if $@