Branch Coverage

blib/lib/CGI/Util.pm
Criterion Covered Total %
branch 40 60 66.7


line true false branch
77 10 175 unless @param
79 2 173 if (ref $param[0] eq 'HASH') { }
83 54 119 unless defined $param[0] and substr($param[0], 0, 1) eq '-'
90 218 622 ref $_ eq 'ARRAY' ? :
99 287 11 if (exists $pos{$key}) { }
106 7 3 defined $CGI::Q ? :
10 111 if %leftover
112 0 70 unless $attr and ref $attr and ref $attr eq 'HASH'
124 70 1 $escape ? :
125 67 4 defined $$attr{$_} ? :
131 4 66 unless defined(my $toencode = shift @_)
144 0 0 if $] >= 5.006
146 0 0 if ($c < 128) { }
0 0 elsif ($c < 2048) { }
0 0 elsif ($c < 65536) { }
0 0 elsif ($c < 2097152) { }
0 0 elsif ($c < 67108864) { }
0 0 elsif ($c < 2147483648) { }
184 0 197 if @_ > 0 and ref $_[0] || defined $_[1] && $_[0] eq $CGI::DefaultClass
186 16 181 unless defined $todecode
189 0 181 if ($EBCDIC) { }
193 34 0 defined $1 ? :
200 4 352 if @_ > 1 and ref $_[0] || defined $_[1] && $_[0] eq $CGI::DefaultClass
202 4 352 unless defined $toencode
205 0 352 if ($EBCDIC) { }
225 1 10 unless $time =~ /^\d+$/
230 5 5 if $format eq 'cookie'
260 5 6 if (not $time or lc $time eq 'now') { }
0 6 elsif ($time =~ /^\d+/) { }
5 1 elsif ($time =~ /^([+-]?(?:\d+|\d*\.\d*))([smhdMy])/) { }