Branch Coverage

blib/lib/Net/FTP/Tiny.pm
Criterion Covered Total %
branch 14 100 14.0


line true false branch
130 33 152 unless defined $host
131 67 85 defined $path ? :
139 8 144 defined $user ? :
4 148 defined $pass ? :
43 109 defined $port ? :
67 85 defined $path ? :
6 146 defined $type ? :
176 0 0 if ($host =~ /\A\[v/)
179 0 0 if ($host =~ /\A\[/)
180 0 0 unless &_socket_class() eq 'IO::Socket::IP'
183 0 0 $host =~ /\A\[(.*)\]\z/s ? :
184 0 0 unless $port >= 1 and $port <= 65535
199 0 0 unless ($loaded_domains)
204 0 0 unless my $sub = *{"Socket::AF_$tag";}{'CODE'}
206 0 0 if defined $val
211 0 0 unless defined $tag
218 0 0 $writing ? :
0 0 $writing ? :
220 0 0 $s ? :
0 0 unless $s >= 1
235 0 0 unless defined $n
244 0 0 if $$rbufp =~ /\A(?:[0-9]{0,2}[^0-9]|[0-9]{3}[^\-\ ])|\r[^\0\n]/
246 0 0 if ($$rbufp =~ s/\A([0-9]{3} (?>(?>(?>[^\r]+)|\r\0)*))\r\n//) { }
0 0 elsif ($$rbufp =~ s/\A ([0-9]{3})-((?>(?>(?>[^\r]+)|\r\0)*)\r\n (?>(?>(?>[^\r]+)|\r\0)*\r\n)*?) \1\ ((?:(?>[^\r]+)|\r\0)*)\r\n //x) { }
259 0 0 unless defined $n
260 0 0 unless $n != 0
275 0 0 &_decode_domain(scalar $ctlconn->sockdomain) eq 'INET' ? :
279 0 0 if ($pasv eq 'PASV' and $r =~ /\A227 .*?($d8_rx(?:,$d8_rx){5})(?![0-9])/so) { }
0 0 elsif ($pasv eq 'EPSV' and $r =~ /\A229 .*?\(([!-~])\1\1([0-9]+)\1\)/s) { }
0 0 elsif (not $r =~ /\A50[02]/) { }
304 0 0 if ($domain eq 'INET') { }
0 0 elsif ($domain eq 'INET6') { }
312 0 0 unless $r =~ /\A200/
318 0 0 unless defined $conn
320 0 0 unless ($conn->peerhost eq $require_peerhost and $conn->peerport == $require_peerport)
332 0 0 unless (exists $params{'username'})
336 0 0 unless defined $params{'filename'}
337 0 0 unless exists $params{'type'}
338 0 0 if $params{'type'} eq 'd'
342 0 0 if $r =~ /\A120/
343 0 0 unless $r =~ /\A220/
346 0 0 if ($r =~ /\A331/ and exists $params{'password'})
350 0 0 unless $r =~ /\A230/
354 0 0 unless $r =~ /\A250/
356 0 0 if ($params{'type'} eq 'i')
359 0 0 unless $r =~ /\A200/
364 0 0 unless $r =~ /\A1(?:25|50)/
371 0 0 unless defined $n
372 0 0 if $n == 0
376 0 0 unless $r =~ /\A2(?:26|50)/