Branch Coverage

blib/lib/DBIx/SchemaChecksum.pm
Criterion Covered Total %
branch 33 54 61.1


line true false branch
75 15 0 if (Class::Load::try_load_class($class))
98 0 13 if ($ref eq 'ARRAY') { }
13 0 elsif ($ref eq 'HASH') { }
139 0 59 unless $table =~ /^"?(?<schema>[^"]+)"?\."?(?<table>[^"]+)"?$/
145 39 20 unless $table_data
163 13 7 if scalar @primary_keys
170 49 0 if $column_data
176 20 0 if ($sth_fk)
182 0 20 if keys %$fk
195 0 49 if (my $default = $relevants->{'COLUMN_DEF'})
196 0 0 if ($default =~ /nextval/)
198 0 0 if ($1)
217 0 9 unless $dir
218 2 7 unless -d $dir
220 0 7 if $self->verbose
228 0 0 unless ($pre or $post)
229 0 0 if $self->verbose
233 3 15 if ($pre eq $post)
234 3 0 if ($update_info{$pre}) { }
237 6 0 unless $item eq 'SAME_CHECKSUM'
246 3 15 if ($update_info{$pre} and $update_info{$pre}[0] eq 'SAME_CHECKSUM') { }
249 3 0 if ($post eq $pre) { }
263 6 1 if %update_info
270 1 21 unless $filename
274 1 20 unless open my $fh, '<', $filename
276 39 75 if (/^--\s+(pre|post)SHA1sum:?\s+([0-9A-Fa-f]{40,})\s+$/)
281 1 39 unless $checksums{$_}