Some cleanups to the m2m warnings test
[dbsrgits/DBIx-Class.git] / t / 93nobindvars.t
index e64dbb6..8a72864 100644 (file)
@@ -40,7 +40,7 @@ my $dbh = $schema->storage->dbh;
 
 $dbh->do("DROP TABLE IF EXISTS artist;");
 
-$dbh->do("CREATE TABLE artist (artistid INTEGER NOT NULL AUTO_INCREMENT PRIMARY KEY, name VARCHAR(255), charfield CHAR(10));");
+$dbh->do("CREATE TABLE artist (artistid INTEGER NOT NULL AUTO_INCREMENT PRIMARY KEY, name VARCHAR(100), rank INTEGER NOT NULL DEFAULT '13', charfield CHAR(10));");
 
 $schema->class('Artist')->load_components('PK::Auto');
 
@@ -65,5 +65,5 @@ is( $it->next, undef, "next past end of resultset ok" );
 
 # clean up our mess
 END {
-    $dbh->do("DROP TABLE artist");
+    $dbh->do("DROP TABLE artist") if $dbh;
 }