Condition Coverage

blib/lib/Crypt/SecretBuffer.pm
Criterion Covered Total %
condition 34 97 35.0


and 3 conditions

line !l l&&!r l&&r condition
63 0 5 42 @_ and ref $_[0]
5 0 42 @_ and ref $_[0] and ref $_[0] eq 'GLOB' || ref($_[0])->can('getc')
131 0 0 0 -t $input_fh and defined $fd && $fd == 0 || \*STDIN == $input_fh || $^O eq 'MSWin32'
167 47 0 0 $ttystate and $ttystate->echo
171 47 0 0 $ttystate and $ttystate->line_input
47 0 0 $ttystate and $ttystate->line_input and $input_by_chars
178 0 1 0 defined $start_len and defined $char_mask
180 0 0 0 $n and $utf8
183 0 0 0 $span->len and eval { do { $span->ltrim(qr/./) } }
187 0 0 1 $prompt_fh->print($state->{'prompt'} . $suffix) and $prompt_fh->flush
207 26 30 0 $utf8 and $ttystate
56 0 0 $utf8 and $ttystate and $^O eq "MSWin32"
241 0 0 0 $prompt_fh->print("\b" x CORE::length($char_mask) . " " x CORE::length($char_mask) . "\b" x CORE::length($char_mask)) and $prompt_fh->flush
279 188 0 0 $char_max and $count >= $char_max
288 0 0 0 $prompt_fh->print($char_mask) and $prompt_fh->flush
292 22 0 0 $char_count and $count == $char_count
295 25 0 0 $char_class and $self->index($char_class, $end_pos) == -1
25 0 0 $char_max and $self->length - $start_len > $char_max
306 0 0 0 $prompt_fh->print($char_mask) and $prompt_fh->flush
310 25 0 0 $char_count and $self->length - $start_len == $char_count
317 40 0 0 $char_max and $self->length - $start_len > $char_max
329 0 1 0 $prompt_fh->print("\n") and $prompt_fh->flush

or 2 conditions

line l !l condition
72 5 42 delete $options{'state'} || {}
120 4 43 $state->{'reading_from'} ||= "supplied_handle"
156 4 1 $state->{'writing_to'} ||= "supplied_handle"
257 0 28 $start_len || 0
355 1 0 $chunksize ||= 65536

or 3 conditions

line l !l&&r !l&&!r condition
63 42 0 0 ref $_[0] eq 'GLOB' || ref($_[0])->can('getc')
87 0 2 0 $state->{'char_class'} ||= qr/[\p{Print}]/
124 5 0 42 defined $state->{'prompt'} or defined $char_mask
131 0 0 0 defined $fd && $fd == 0 || \*STDIN == $input_fh || $^O eq 'MSWin32'
0 0 0 -S $input_fh or -t $input_fh
162 7 0 40 defined $char_mask || defined $char_count || defined $char_class || defined $timeout || $utf8
165 0 0 47 $state->{'ttystate'} ||= "Crypt::SecretBuffer::ConsoleState"->maybe_new("handle", $input_fh)