Branch Coverage

blib/lib/CGI/Plus.pm
Criterion Covered Total %
branch 44 72 61.1


line true false branch
207 0 18 if (defined $cookie->expires)
214 9 9 if (@value > 1) { }
247 0 2 unless ($cgi->ic->{$name} or $opts{'ensure'})
262 1 3 if (UNIVERSAL::isa($value, 'CGI::Cookie')) { }
1 2 elsif (UNIVERSAL::isa($value, 'HASH')) { }
413 6 0 unless ($rv = $ENV{'PATH_INFO'})
419 4 2 unless ($opts{'clear_params'})
430 4 5 if (exists $$changes{$key}) { }
431 1 3 if (ref $$changes{$key}) { }
446 7 5 if ($query) { }
460 5 1 if ($query)
464 0 6 if ($opts{'html'})
523 0 3 if ($$cgi{'header_sent'})
527 1 2 if (not $opts{'-type'} and $$cgi{'content_type'})
532 1 2 if ($$cgi{'headers'})
545 1 0 if ($element{'values'}) { }
0 0 elsif (not defined $element{'value'}) { }
555 1 1 if ($key eq 'values') { }
569 0 1 if ($element{'domain'})
573 0 1 if (exists $element{'expires'}) { }
574 0 0 if (defined $element{'expires'})
584 0 1 unless (defined $cookie)
594 1 2 if (@cookies)
637 1 5 if (@_)
641 1 0 if ($$cgi{'csrf'})
683 0 0 unless ($cgi->csrf)
691 0 0 unless $cookie
720 0 1 unless ($cgi->csrf)
728 0 1 unless $cookie
768 0 1 unless ($cgi->csrf)
776 0 1 unless $cookie
812 0 1 unless ($cgi->csrf)
820 0 1 unless $cookie
824 0 1 unless $cookie_value
828 1 0 unless $form_value
831 0 0 if ($cookie_value eq $form_value)