Author: timbo
Date: Sat May 15 04:12:48 2004
New Revision: 345
Modified:
dbi/trunk/Changes
dbi/trunk/t/40profile.t
Log:
Tweak t/40profile.t for perl 5.6 vs 5.8 difference in DESTROY behaviour.
Tweak Changes file.
Modified: dbi/trunk/Changes
==============================================================================
--- dbi/trunk/Changes (original)
+++ dbi/trunk/Changes Sat May 15 04:12:48 2004
@@ -25,7 +25,7 @@
Changed selectall_arrayref() to call finish() if
$attr->{MaxRows} is defined.
Changed all tests to use Test::More and enhanced the tests thanks
- to Andy Lester and Stevan Little. http://qa.perl.org/phalanx/
+ to Stevan Little and Andy Lester. See http://qa.perl.org/phalanx/
Changed Test::More minimum prerequisite version to 0.40 (2001).
Added warning if build directory path contains whitespace.
Modified: dbi/trunk/t/40profile.t
==============================================================================
--- dbi/trunk/t/40profile.t (original)
+++ dbi/trunk/t/40profile.t Sat May 15 04:12:48 2004
@@ -153,8 +153,11 @@
my $do_sql = "set foo=1";
$dbh->do($do_sql); # check dbh do() gets associated with right statement
-ok(keys %{$data->{$do_sql}}, 1); # XXX extra one is DESTROY
ok(exists $data->{$do_sql}{do});
+# In perl 5.6 the sth DESTROY gets included. In perl 5.8 it doesn't.
+ok(keys %{$data->{$do_sql}},
+ (exists $data->{$do_sql}{DESTROY}) ? 2 : 1);
+
print "Profile Data keys: @{[ keys %{$data->{$do_sql}} ]}\n";