Condition Coverage

blib/lib/CGI/Lingua.pm
Criterion Covered Total %
condition 23 112 20.5


and 3 conditions

line !l l&&!r l&&r condition
126 31 0 0 $cache and $ENV{'REMOTE_ADDR'}
129 0 0 0 $info and $l = $info->lang
152 0 0 0 $rc->{'_what_language'} || $rc->{'_rlanguage'} and $info
0 0 0 $rc->{'_what_language'} || $rc->{'_rlanguage'} and $info and $info->lang
184 0 0 31 defined $^V and $^V ge "v5.14.0"
432 17 1 3 not $l and $http_accept_language =~ /(.+)-.+/
540 0 0 13 $variety =~ /[a-z]{2,3}/ and not defined $self->{'_sublanguage'}
588 13 0 0 $self->{'_cache'} and not defined $from_cache
604 0 2 0 $self->{'_slanguage'} and $self->{'_slanguage'} ne "Unknown"
620 0 2 0 !$self->{'_rlanguage'} || $self->{'_rlanguage'} eq 'Unknown' and length $http_accept_language == 2 || $http_accept_language =~ /^..-..$/
640 0 1 2 not defined $country and my $c = $self->_what_language
672 0 0 0 $self->{'_logger'} and $language_name
683 0 0 0 exists $self->{'_slanguage'} and $self->{'_slanguage'} ne "Unknown"
688 0 0 0 $language_name and $language_code2
0 0 0 $language_name and $language_code2 and not defined $http_accept_language
700 0 0 0 $http_accept_language and $http_accept_language ne $self->{'_rlanguage'}
727 0 0 0 do {
736 0 0 0 not defined $from_cache and $self->{'_cache'}
0 0 0 not defined $from_cache and $self->{'_cache'} and defined $self->{'_slanguage_code_alpha2'}
851 10 0 2 $ENV{'HTTP_CF_IPCOUNTRY'} and $ENV{'HTTP_CF_IPCOUNTRY'} ne "XX"
950 0 0 0 $self->{'_country'} and $self->{'_country'} eq "eu"
953 0 0 0 not $self->{'_country'} and eval {
989 0 0 0 $self->{'_country'} eq "US" and $whois->{'StateProv'} eq "PR"
1118 0 0 1 defined $agent and $agent =~ /\((.+)\)/
1139 0 0 1 $browser and $browser->country

or 2 conditions

line l !l condition
178 0 31 $params{'dont_use_ip'} || 0
0 31 $params{'debug'} || 0

or 3 conditions

line l !l&&r !l&&!r condition
111 1 32 0 ref $proto || $proto
152 0 0 0 $rc->{'_what_language'} || $rc->{'_rlanguage'}
578 0 0 13 $@ or not defined $language_name
620 0 2 0 !$self->{'_rlanguage'} || $self->{'_rlanguage'} eq 'Unknown'
1 0 1 length $http_accept_language == 2 || $http_accept_language =~ /^..-..$/
680 0 0 0 not defined $self->{'_rlanguage'} or $self->{'_rlanguage'} eq "Unknown"
710 0 0 0 not defined $http_accept_language or $1 ne $self->{'_rlanguage'}
982 0 0 0 $@ or not defined $whois
0 0 0 $@ or not defined $whois or ref $whois ne "HASH"
1069 0 0 0 $^O eq "MSWin32" or -r "/usr/local/share/GeoIP/GeoIP.dat"
0 0 0 $^O eq "MSWin32" or -r "/usr/local/share/GeoIP/GeoIP.dat" or -r "/usr/share/GeoIP/GeoIP.dat"