This patch adds two warning messages to places in the test suite that
may fail. I don't think it changes any functionality, but it sure makes
it easier to figure out what has gone wrong.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
if ($id) {
# we have found 1 foreign, drop it
$dbh->do("ALTER TABLE $table DROP FOREIGN KEY $id");
- $id="";
+ if ( $dbh->err ) {
+ diag "unable to DROP FOREIGN KEY '$id' on TABLE '$table' due to: " . $dbh->errstr();
+ }
+ undef $id;
}
}
}
sub drop_table {
my ($dbh, $table) = @_;
$dbh->do("DROP TABLE $table");
+ if ( $dbh->err ) {
+ diag "unable to drop table: '$table' due to: " . $dbh->errstr();
+ }
}
=head3 create_test_database