Branch Coverage

blib/lib/Net/SSH/Perl/Util/Hosts.pm
Criterion Covered Total %
branch 0 82 0.0


line true false branch
18 0 0 if (defined $port and $port != 22)
23 0 0 unless open my $fh, "<", $hostfile
30 0 0 unless $keyblob
36 0 0 if $@
41 0 0 if (index($hosts, "|") == 0)
42 0 0 unless ($hosts =~ /^\|1\|(.+?)\|/)
54 0 0 if ($h eq $checkhost and $key->ssh_name eq $fkey->ssh_name)
55 0 0 $key->equal($fkey) ? :
67 0 0 if ($host =~ /[a-zA-Z]+/)
70 0 0 if (defined $port and $port != 22)
75 0 0 unless open my $fh, "<", $hostfile
83 0 0 if $ip
87 0 0 if (index($hosts, "|") == 0)
88 0 0 unless ($hosts =~ /^\|1\|(.+?)\|/)
99 0 0 if ($h eq $checkhost)
102 0 0 if $fkey
108 0 0 wantarray ? :
113 0 0 unless (-e $hostfile)
116 0 0 unless (-d $dir)
118 0 0 unless File::Path::mkpath([$dir])
124 0 0 if ($host =~ /[a-zA-Z]+/)
126 0 0 if $ip and defined $port and $port != 22
128 0 0 if defined $port and $port != 22
131 0 0 unless open my $fh, ">>", $hostfile
132 0 0 if ($hash_flag) { }
135 0 0 if $ip
144 0 0 if $ip
148 0 0 unless close $fh
153 0 0 unless -e $hostfile
156 0 0 if ($host =~ /[a-zA-Z]+/)
158 0 0 if $ip and defined $port and $port != 22
160 0 0 if defined $port and $port != 22
162 0 0 unless open my $fh, "<", $hostfile
163 0 0 unless open my $fhw, ">", "$hostfile.new"
174 0 0 if ($@)
180 0 0 if $ip
184 0 0 if (index($hosts, "|") == 0)
185 0 0 unless ($hosts =~ /^\|1\|(.+?)\|/)
197 0 0 if ($h eq $checkhost and $key->equal($fkey))
204 0 0 unless close $fhw
205 0 0 unless close $fh