Condition Coverage

blib/lib/DBIx/QueryLog.pm
Criterion Covered Total %
condition 103 153 67.3


and 3 conditions

line !l l&&!r l&&r condition
124 17 0 0 $probability and int((rand()) * $probability) % $probability != 0
145 9 0 8 $container->{'skip_bind'} || $ENV{'DBIX_QUERYLOG_SKIP_BIND'} and @params
184 12 0 0 $probability and int((rand()) * $probability) % $probability != 0
195 11 0 1 $container->{'skip_bind'} || $ENV{'DBIX_QUERYLOG_SKIP_BIND'} and @bind
225 0 0 332 $dbh->{'Driver'}{'Name'} ne 'mysql' and $dbh->{'Driver'}{'Name'} ne 'Pg'
0 8 324 $dbh->{'Driver'}{'Name'} eq 'SQLite' && 1 && !@bind
0 324 8 $dbh->{'Driver'}{'Name'} ne 'mysql' and $dbh->{'Driver'}{'Name'} ne 'Pg' and not $dbh->{'Driver'}{'Name'} eq 'SQLite' && 1 && !@bind
230 124 24 176 $probability and int((rand()) * $probability) % $probability != 0
241 148 0 0 $container->{'skip_bind'} || $ENV{'DBIX_QUERYLOG_SKIP_BIND'} and @bind
295 4 0 10 defined $args{'print'} and $args{'print'}
315 0 0 0 $pos >= 6 && substr($ret, $pos - 6, 6) =~ /\A[Ll](?:IMIT|imit) \z/
322 0 0 0 defined $type and $dbh->{'Driver'}{'Name'} eq 'Pg'
0 0 0 defined $type and $dbh->{'Driver'}{'Name'} eq 'Pg' and $type == 0
373 46 141 97 not $quote_char and $s eq ' ' || $s eq "\n" || $s eq "\t" || $s eq "\r"
1 133 33 not $before_escape and $quote_char
134 32 1 not $before_escape and $quote_char and $s eq '\\'
394 127 0 4 $s eq ')' || $s eq ',' and substr($buff, -1, 1) eq ' '

or 2 conditions

line l !l condition
164 3 7 $sth->{'private_DBIx_QueryLog_params'} ||= []
165 3 7 $sth->{'private_DBIx_QueryLog_attrs'} ||= []
166 0 10 $attr || 0
257 2 14 $types ||= []
307 23 159 $types ||= []
346 173 0 $bind_params ||= []

or 3 conditions

line l !l&&r !l&&!r condition
47 2 22 0 $st_execute ||= $class->_st_execute(sub ; )
48 2 22 0 $st_bind_param ||= $class->_st_bind_param(sub ; )
49 2 22 0 $db_do ||= $class->_db_do(sub ; )
51 2 22 0 $selectall_arrayref ||= $class->_select_array(sub ; )
52 2 22 0 $selectrow_arrayref ||= $class->_select_array(sub ; )
53 2 22 0 $selectrow_array ||= $class->_select_array(sub ; , 1)
123 0 0 17 $container->{'probability'} || $ENV{'DBIX_QUERYLOG_PROBABILITY'}
141 1 1 15 $container->{'explain'} or $ENV{'DBIX_QUERYLOG_EXPLAIN'}
145 5 3 9 $container->{'skip_bind'} || $ENV{'DBIX_QUERYLOG_SKIP_BIND'}
183 0 0 12 $container->{'probability'} || $ENV{'DBIX_QUERYLOG_PROBABILITY'}
191 3 3 6 $container->{'explain'} or $ENV{'DBIX_QUERYLOG_EXPLAIN'}
195 1 0 11 $container->{'skip_bind'} || $ENV{'DBIX_QUERYLOG_SKIP_BIND'}
229 100 100 124 $container->{'probability'} || $ENV{'DBIX_QUERYLOG_PROBABILITY'}
237 4 4 140 $container->{'explain'} or $ENV{'DBIX_QUERYLOG_EXPLAIN'}
241 0 0 148 $container->{'skip_bind'} || $ENV{'DBIX_QUERYLOG_SKIP_BIND'}
278 0 0 14 $dbh->{'Driver'}{'Name'} eq 'mysql' or $dbh->{'Driver'}{'Name'} eq 'Pg'
309 0 0 182 $dbh->{'Driver'}{'Name'} eq 'mysql' or $dbh->{'Driver'}{'Name'} eq 'Pg'
313 0 0 0 $limit_flag ||= do { my $pos = pos $ret; $pos >= 6 && substr($ret, $pos - 6, 6) =~ /\A[Ll](?:IMIT|imit) \z/ ? 1 : 0 }
343 1 1 173 $container->{'threshold'} || $ENV{'DBIX_QUERYLOG_THRESHOLD'}
344 173 0 2 not $threshold or $time > $threshold
351 8 8 173 $SKIP_PKG_MAP{$c[0]} or $c[0] =~ /^DB[DI]::/
358 6 3 164 $container->{'skip_bind'} or $ENV{'DBIX_QUERYLOG_SKIP_BIND'}
366 2 0 171 $container->{'compact'} or $ENV{'DBIX_QUERYLOG_COMPACT'}
373 10 1 141 $s eq ' ' || $s eq "\n" || $s eq "\t" || $s eq "\r"
16 4 167 $s eq q['] or $s eq '"'
20 0 167 $s eq q['] or $s eq '"' or $s eq '`'
394 2 2 127 $s eq ')' || $s eq ','
409 2 0 171 $container->{'useqq'} or $ENV{'DBIX_QUERYLOG_USEQQ'}
416 1 0 172 $container->{'color'} || $ENV{'DBIX_QUERYLOG_COLOR'}
426 1 1 171 $container->{'show_data_source'} || $ENV{'DBIX_QUERYLOG_SHOW_DATASOURCE'}