X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Flib%2FDBICTest.pm;h=ee5579281b5a1aa23110d213e7fb694120b345ef;hb=f66c9ba8c90d9ee27e4eb0ed0215d28d82dbc574;hp=d1d53c59057d356e365814f410a69fbb040f8f53;hpb=ab340f7f379ff7c39908a01e82ca337009275eb1;p=dbsrgits%2FDBIx-Class-Historic.git diff --git a/t/lib/DBICTest.pm b/t/lib/DBICTest.pm index d1d53c5..ee55792 100644 --- a/t/lib/DBICTest.pm +++ b/t/lib/DBICTest.pm @@ -75,7 +75,7 @@ sub _database { my $dbuser = $ENV{"DBICTEST_DBUSER"} || ''; my $dbpass = $ENV{"DBICTEST_DBPASS"} || ''; - my @connect_info = ($dsn, $dbuser, $dbpass, { AutoCommit => 1 }); + my @connect_info = ($dsn, $dbuser, $dbpass, { AutoCommit => 1, %args }); return @connect_info; } @@ -135,7 +135,7 @@ sub deploy_schema { close IN; for my $chunk ( split (/;\s*\n+/, $sql) ) { if ( $chunk =~ / ^ (?! --\s* ) \S /xm ) { # there is some real sql in the chunk - a non-space at the start of the string which is not a comment - $schema->storage->dbh->do($chunk) or print "Error on SQL: $chunk\n"; + $schema->storage->dbh_do(sub { $_[1]->do($chunk) }) or print "Error on SQL: $chunk\n"; } } } @@ -310,7 +310,7 @@ sub populate_schema { ]); $schema->populate('Owners', [ - [ qw/ownerid name/ ], + [ qw/id name/ ], [ 1, "Newton" ], [ 2, "Waltham" ], ]);