Branch Coverage

blib/lib/Perl/Lint/Policy/InputOutput/RequireCheckedOpen.pm
Criterion Covered Total %
branch 56 78 71.7


line true false branch
26 4 367 if ($token_type == 65)
31 8 359 if ($token_type == 94)
32 4 4 if ($token_data eq 'Fatal') { }
4 0 elsif ($token_data eq 'autodie') { }
35 2 2 if ($next_token_type == 147) { }
1 1 elsif ($next_token_type == 107) { }
1 0 elsif ($next_token_type == 172 || $next_token_type == 173 and $next_token->{'data'} eq 'open') { }
38 1 2 if ($token_type == 187 and $token->{'data'} eq 'open') { }
1 1 elsif ($token_type == 151) { }
50 0 1 if ($token_type == 107) { }
1 0 elsif ($token_type == 172 || $token_type == 173 and $token->{'data'} eq 'open') { }
57 0 0 if --$left_paren_num <= 0
66 2 2 if ($$tokens[$i + 1]{'type'} == 147) { }
69 1 3 if ($token_type == 187 and $token->{'data'} =~ /\A\s*:io\s*\Z/) { }
2 1 elsif ($token_type == 151) { }
85 1 358 if ($token_type == 127 and $token_data eq 'Fatal')
87 1 0 if ($skipped_token and $skipped_token->{'type'} == 127 and $skipped_token->{'data'} eq 'Exception')
90 1 2 if ($token_type == 147) { }
0 2 elsif ($token_type == 107) { }
0 2 elsif ($token_type == 172 || $token_type == 173 and $token->{'data'} eq 'open') { }
0 2 elsif ($token->{'kind'} == 21) { }
93 1 0 if ($token_type == 187 and $token->{'data'} eq 'open') { }
0 0 elsif ($token_type == 151) { }
105 0 0 if ($token_type == 107) { }
0 0 elsif ($token_type == 172 || $token_type == 173 and $token->{'data'} eq 'open') { }
112 0 0 if --$left_paren_num <= 0
128 13 345 if ($token_kind == 17)
131 1 12 if ($$tokens[$i + 1]{'type'} == 107)
136 0 1 if ($token_type == 107) { }
140 1 0 if --$left_paren_num <= 0
147 47 298 if ($token_type == 70)
148 36 11 if ($token_data eq 'open') { }
1 10 elsif ($token_data eq 'no') { }
149 20 12 unless ($is_in_assign_context or $is_in_statement_context)
155 1 0 if ($next_token->{'type'} == 122 and $next_token->{'data'} eq 'autodie')
162 6 292 if ($token_kind == 1)
167 44 248 if ($token_kind == 21)
168 5 39 if $is_enabled_autodie
170 12 27 if ($is_called_open_in_void)