From 2e38f936a65ba0a360553c90dc3916d7e15b32f5 Mon Sep 17 00:00:00 2001 From: Brian Fraser Date: Wed, 15 Aug 2012 13:26:13 -0300 Subject: [PATCH] Silence rollback warnings in t/lib/DSNParser.t --- t/lib/DSNParser.t | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/t/lib/DSNParser.t b/t/lib/DSNParser.t index 91c28cc5..179317a2 100644 --- a/t/lib/DSNParser.t +++ b/t/lib/DSNParser.t @@ -9,7 +9,7 @@ BEGIN { use strict; use warnings FATAL => 'all'; use English qw(-no_match_vars); -use Test::More tests => 37; +use Test::More; use DSNParser; use OptionParser; @@ -545,6 +545,9 @@ foreach my $password_comma ( @password_commas ) { # ############################################################################# # Bug 984915: SQL calls after creating the dbh aren't checked # ############################################################################# +# Make sure to disconnect any lingering dbhs, since full_output will fork +# and then die, which will cause rollback warnings for connected dbhs. +$dbh->disconnect() if $dbh; $dsn = $dp->parse('h=127.1,P=12345,u=msandbox,p=msandbox'); my @opts = $dp->get_cxn_params($dsn); @@ -569,5 +572,4 @@ like( # ############################################################################# # Done. # ############################################################################# -$dbh->disconnect() if $dbh; -exit; +done_testing;