Branch Coverage

blib/lib/ParseUtil/Domain.pm
Criterion Covered Total %
branch 37 42 88.1


line true false branch
41 61 3 if $domain_name
43 61 3 if $name_ace
48 2 62 if (@name_segments > 1)
55 2 0 if ($domain_ace)
68 0 0 if ($domain =~ /\.?xn--/u) { }
93 40 32 if $thld
94 3 69 if ($tld =~ /^de$/u) { }
100 40 29 if $thld_zone_ace
107 10 62 if ($possible_thld and $possible_thld =~ /\A$tld_regex\z/u) { }
24 38 elsif ($possible_tld =~ /\A$tld_regex\z/u) { }
37 1 elsif ($tld_zone_ace =~ /\A$tld_regex\z/u) { }
122 12 25 if $thld
127 1 71 unless $zone
140 68 5 unless ($zone and $zone =~ /^(?:de|fr|pm|re|tf|wf|yt)$/u)
143 6 85 if not defined $segment or $segment eq ''
154 1 61 if any sub { lc $_ ne nameprep(lc $_); } , @{$puny_decoded;}
196 126 6 if $name
197 44 88 if $prefix
209 6 2 if $test_encode eq $unencoded
215 0 5 unless $encoded =~ /xn--/u
221 0 5 if $encoded eq $test_decode