Branch Coverage

blib/lib/HealthCheck/Diagnostic/DBHCheck.pm
Criterion Covered Total %
branch 35 38 92.1


line true false branch
20 0 7 @params == 1 && (ref $params[0] || '') eq 'HASH' ? :
23 1 6 if $params{'dbh'} and ref $params{'dbh'} ne "CODE"
38 6 10 if ref $self
40 2 14 unless $dbh
42 1 13 unless ref $dbh eq "CODE"
49 1 12 unless $db_access =~ /^r[ow]$/
55 1 10 ref $self && defined $self->{'timeout'} ? :
1 11 defined $params{'timeout'} ? :
66 2 10 if ($@ =~ /^timeout/)
75 2 8 if $@
77 2 6 unless &blessed($dbh)
86 1 5 unless $dbh->isa($db_class)
134 2 0 if $row[0] and $row[0] eq "Hello world"
153 2 3 if ($dbh->can("ping") and not $dbh->ping)
160 0 3 unless (defined $value and $value == 1)
165 2 1 if $read_write
175 3 2 $status eq 'OK' ? :
4 1 $read_write ? :
2 3 $dbh->{'Username'} ? :