Author: turnstep
Date: Tue Jan 15 17:29:51 2008
New Revision: 10563

Modified:
   DBD-Pg/trunk/t/03dbmethod.t
   DBD-Pg/trunk/t/09arrays.t

Log:
More testing tweaks.


Modified: DBD-Pg/trunk/t/03dbmethod.t
==============================================================================
--- DBD-Pg/trunk/t/03dbmethod.t (original)
+++ DBD-Pg/trunk/t/03dbmethod.t Tue Jan 15 17:29:51 2008
@@ -131,10 +131,10 @@
 $t=q{ DB handle method "last_insert_id" fails when the sequence name is 
changed and cache is used};
 
 SKIP: {
-       if ($pgversion < 80200) {
+       if ($pgversion < 80300) {
                $dbh->do("DROP TABLE $schema2.$table2");
                $dbh->do("DROP SEQUENCE $schema2.$sequence2");
-               skip 'Cannot test sequence rename on pre-8.2 servers', 2;
+               skip 'Cannot test sequence rename on pre-8.3 servers', 2;
        }
        $dbh->do("ALTER SEQUENCE $schema2.$sequence2 RENAME TO $sequence3");
        $dbh->commit();

Modified: DBD-Pg/trunk/t/09arrays.t
==============================================================================
--- DBD-Pg/trunk/t/09arrays.t   (original)
+++ DBD-Pg/trunk/t/09arrays.t   Tue Jan 15 17:29:51 2008
@@ -13,7 +13,7 @@
 select(($|=1,select(STDERR),$|=1)[1]);
 
 if (defined $ENV{DBI_DSN}) {
-       plan tests => 196;
+       plan tests => 214;
 } else {
        plan skip_all => 'Cannot run test unless DBI_DSN is defined. See the 
README file';
 }
@@ -183,13 +183,13 @@
                }
        }
 
-
        $cleararray->execute();
        eval {
                $addarray->execute(eval $input);
        };
        if ($expected =~ /error:\s+(.+)/i) {
                like($@, qr{$1}, "Array failed : $msg : $input");
+               like($@, qr{$1}, "Array failed : $msg : $input");
        }
        else {
                is($@, q{}, "Array worked : $msg : $input");
@@ -205,6 +205,7 @@
                my $errmsg = $1;
                $errmsg =~ s/bind/quote/;
                like($@, qr{$errmsg}, "Array quote failed : $msg : $input");
+               like($@, qr{$errmsg}, "Array quote failed : $msg : $input");
        }
        else {
                is($@, q{}, "Array quote worked : $msg : $input");
@@ -229,7 +230,7 @@
                my $ver = $1;
                if ($pgversion < $ver) {
                  SKIP: {
-                               skip 'Cannot test NULL arrays unless version 
8.2 or better', 4;
+                               skip 'Cannot test NULL arrays unless version 
8.2 or better', 2;
                        }
                        next;
                }
@@ -241,6 +242,7 @@
        };
        if ($expected =~ /error:\s+(.+)/i) {
                like($@, qr{$1}, "Array failed : $msg : $input");
+               like($@, qr{$1}, "Array failed : $msg : $input");
        }
        else {
                is($@, q{}, "Array worked : $msg : $input");

Reply via email to