From b3f41261e52df5e7f59a68100680759c1a2039bd Mon Sep 17 00:00:00 2001 From: Rafael Kitover Date: Wed, 1 Jul 2009 13:25:46 +0000 Subject: [PATCH] add a couple of dbd::sybase reconnection tests --- t/746sybase.t | 3 +++ t/74mssql.t | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/t/746sybase.t b/t/746sybase.t index f09862f57..10378cfcc 100644 --- a/t/746sybase.t +++ b/t/746sybase.t @@ -14,7 +14,10 @@ plan tests => 12; my $schema = DBICTest::Schema->connect($dsn, $user, $pass, {AutoCommit => 1}); +# start disconnected to test reconnection $schema->storage->ensure_connected; +$schema->storage->disconnect; + isa_ok( $schema->storage, 'DBIx::Class::Storage::DBI::Sybase' ); $schema->storage->dbh_do (sub { diff --git a/t/74mssql.t b/t/74mssql.t index 72e655251..7de09eff9 100644 --- a/t/74mssql.t +++ b/t/74mssql.t @@ -22,6 +22,10 @@ plan tests => 6; my $schema = DBICTest::Schema->clone; $schema->connection($dsn, $user, $pass); +# start disconnected to test reconnection +$schema->storage->ensure_connected; +$schema->storage->disconnect; + my $dbh = $schema->storage->dbh; isa_ok($schema->storage, 'DBIx::Class::Storage::DBI::Sybase::Microsoft_SQL_Server');