Branch Coverage

blib/lib/Net/IDN/Encode.pm
Criterion Covered Total %
branch 25 32 78.1


line true false branch
44 0 88 if $label =~ /\p{IsIDNADot}/o
46 16 72 if ($label =~ /\P{ASCII}/o) { }
49 0 72 if length $label < 1
50 0 72 if length $label > 63
57 0 91 if $label =~ /\p{IsIDNADot}/o
59 29 62 if ($label =~ /\P{ASCII}|^(?:(?i)$IDNA_PREFIX)/o)
67 48 8 unless exists $param{'UseSTD3ASCIIRules'}
71 54 55 $ascii ? :
165 109 $even_odd++ % 2 ? :
77 8 18 if not defined $email or $email eq ''
79 0 18 unless $email =~ /^( (?(?!\p{IsIDNAAtsign}|").|(?!))+ | "(?:(?:[^"]|\\.)*[^\\])?" ) (?: (\p{IsIDNAAtsign}) (?:([^\[\]]*)|(\[.*\]))? )?$/ox
90 0 18 if $local_part =~ /\P{ASCII}/
91 0 18 if $domain_literal
93 14 4 if $domain
94 9 9 if $ascii
96 14 4 $domain || $domain_literal ? :