Branch Coverage

blib/lib/Crypt/SecretBuffer/PEM.pm
Criterion Covered Total %
branch 43 62 69.3


line true false branch
15 10 0 !exists $options{'trim_headers'} ? :
19 0 9 unless $label and $span->parse("-----\n")
27 0 9 unless ($end)
39 0 9 unless ($block->span($end->pos - $begin->pos - 1, 1)->ends_with("\n"))
46 5 8 if ($sep_or_eol->starts_with(':')) { }
49 5 0 unless $notrim
52 0 5 unless my $eol = $inner->scan("\n")
56 0 5 $notrim ? :
58 2 3 if ($secret_headers) { }
67 3 5 if (@headers)
68 3 0 if ($sep_or_eol->pos == $inner->pos) { }
108 9 0 if @_ > 1
109 9 21 if @_ > 1
110 11 12 if @_ > 1
112 10 15 if (@_ > 1)
116 0 10 if defined $_[0]{'headers'}
131 0 13 unless ref $kv eq "ARRAY" and $kv->$#* & 1
135 0 13 unless defined $k
137 0 13 unless utf8::downgrade($k, 1)
140 0 13 if $k =~ /[\0-\x1F\x7F:]/
142 1 12 if $k =~ /^\s/ or $k =~ /\s\z/
144 0 13 unless defined $v
147 0 13 unless $is_secret or utf8::downgrade($v, 1)
149 2 11 $is_secret ? :
0 13 if $is_secret ? $v->scan(qr/[\0-\x1F\x7F]/) : $v =~ /[\0-\x1F\x7F]/
152 2 11 $is_secret ? :
0 13 if $is_secret ? $v->scan(qr/[\s]/, 2048) || $v->scan(qr/[\s]/, 2304) : $v =~ /^\s/ || $v =~ /\s\z/
163 0 6 unless $self->header_kv
164 3 3 if (@header_kv)
169 5 5 $_ & 1 ? :
175 5 1 $content_span->length ? :