Condition Coverage

blib/lib/Queue/DBI.pm
Criterion Covered Total %
condition 55 79 69.6


and 3 conditions

line !l l&&!r l&&r condition
197 17 30 1 defined $args{'cleanup_timeout'} and not $args{'cleanup_timeout'} =~ /^\d+$/
199 42 4 1 defined $args{'lifetime'} and not $args{'lifetime'} =~ /^\d+$/
201 42 3 1 defined $args{'serializer_freeze'} and not Data::Validate::Type::is_coderef($args{'serializer_freeze'})
203 41 3 1 defined $args{'serializer_thaw'} and not Data::Validate::Type::is_coderef($args{'serializer_thaw'})
244 6 0 36 defined $data && scalar @$data != 0
249 6 0 36 defined $queue_id and $queue_id =~ /^\d+$/
336 0 0 11 defined $data && scalar @$data != 0 && defined $data->[0]
456 2 5 25 defined $elements && scalar @$elements != 0
497 0 0 32 defined $number_of_elements_to_retrieve and $number_of_elements_to_retrieve =~ /^\d+$/
519 0 0 21 defined $data && scalar @$data != 0
788 3 4 0 defined $max_requeue_count and not $max_requeue_count =~ /^\d+$/
790 4 3 0 defined $lifetime and not $lifetime =~ /^\d+$/
792 4 2 1 defined $lifetime and defined $max_requeue_count
869 26 10 0 defined $max_requeue_count and not $max_requeue_count =~ /^\d+$/
914 32 6 0 defined $lifetime and not $lifetime =~ /^\d+$/
991 0 14 2 defined $self->{'serializer'} && defined $self->{'serializer'}{'freeze'}
1008 0 27 2 defined $self->{'serializer'} && defined $self->{'serializer'}{'thaw'}
1110 30 0 12 defined $self->{'table_names'}{'queues'} && $self->{'table_names'}{'queues'} ne ''
1128 165 0 0 defined $self->{'table_names'}{'queue_elements'} && $self->{'table_names'}{'queue_elements'} ne ''

or 2 conditions

line l !l condition
307 3 8 delete $args{'exclude_locked_elements'} || 0
708 30 0 $time_in_seconds ||= ''
970 0 36 $verbose || 0

or 3 conditions

line l !l&&r !l&&!r condition
194 2 0 97 not defined $args{$arg} or $args{$arg} eq ''
596 0 2 25 not defined $data or scalar @$data == 0
794 2 0 4 defined $lifetime or defined $max_requeue_count
806 5 0 0 $dbh->do(sprintf("\n\t\t\t\tDELETE\n\t\t\t\tFROM %s\n\t\t\t\tWHERE queue_id = ?\n\t\t\t\t\tAND lock_time IS NULL\n\t\t\t\t\t%s\n\t\t\t\t\t%s\n\t\t\t", $dbh->quote_identifier($self->get_queue_elements_table_name), $sql_lifetime, $sql_max_requeue_count), {}, $self->get_queue_id) || croak('Cannot execute SQL: ' . $dbh->errstr)

xor 4 conditions

line l&&r l&&!r !l&&r !l&&!r condition
205 2 1 1 40 defined $args{'serializer_freeze'} xor defined $args{'serializer_thaw'}