[Bast-commits] r6962 - in DBIx-Class/0.08/branches/mssql_top_fixes:
. lib/DBIx/Class/Storage/DBI t
ribasushi at dev.catalyst.perl.org
ribasushi at dev.catalyst.perl.org
Fri Jul 3 10:47:57 GMT 2009
Author: ribasushi
Date: 2009-07-03 10:47:57 +0000 (Fri, 03 Jul 2009)
New Revision: 6962
Modified:
DBIx-Class/0.08/branches/mssql_top_fixes/Makefile.PL
DBIx-Class/0.08/branches/mssql_top_fixes/lib/DBIx/Class/Storage/DBI/Pg.pm
DBIx-Class/0.08/branches/mssql_top_fixes/t/72pg.t
DBIx-Class/0.08/branches/mssql_top_fixes/t/from_subquery.t
Log:
Ask for newer DBD::Pg in author mode, suggest the newer version otherwise (proper array support). Make test more resilient as well
Modified: DBIx-Class/0.08/branches/mssql_top_fixes/Makefile.PL
===================================================================
--- DBIx-Class/0.08/branches/mssql_top_fixes/Makefile.PL 2009-07-03 10:06:57 UTC (rev 6961)
+++ DBIx-Class/0.08/branches/mssql_top_fixes/Makefile.PL 2009-07-03 10:47:57 UTC (rev 6962)
@@ -94,6 +94,7 @@
$ENV{DBICTEST_PG_DSN}
? (
'Sys::SigAction' => 0,
+ 'DBD::Pg' => 2.009002,
'DateTime::Format::Pg' => 0,
) : ()
,
Modified: DBIx-Class/0.08/branches/mssql_top_fixes/lib/DBIx/Class/Storage/DBI/Pg.pm
===================================================================
--- DBIx-Class/0.08/branches/mssql_top_fixes/lib/DBIx/Class/Storage/DBI/Pg.pm 2009-07-03 10:06:57 UTC (rev 6961)
+++ DBIx-Class/0.08/branches/mssql_top_fixes/lib/DBIx/Class/Storage/DBI/Pg.pm 2009-07-03 10:47:57 UTC (rev 6962)
@@ -3,15 +3,14 @@
use strict;
use warnings;
-use DBD::Pg qw(:pg_types);
-
use base qw/DBIx::Class::Storage::DBI::MultiColumnIn/;
+use mro 'c3';
-# __PACKAGE__->load_components(qw/PK::Auto/);
+use DBD::Pg qw(:pg_types);
-# Warn about problematic versions of DBD::Pg
-warn "DBD::Pg 1.49 is strongly recommended"
- if ($DBD::Pg::VERSION < 1.49);
+# Ask for a DBD::Pg with array support
+warn "DBD::Pg 2.9.2 or greater is strongly recommended"
+ if ($DBD::Pg::VERSION < 2.009002); # pg uses (used?) version::qv()
sub with_deferred_fk_checks {
my ($self, $sub) = @_;
Modified: DBIx-Class/0.08/branches/mssql_top_fixes/t/72pg.t
===================================================================
--- DBIx-Class/0.08/branches/mssql_top_fixes/t/72pg.t 2009-07-03 10:06:57 UTC (rev 6961)
+++ DBIx-Class/0.08/branches/mssql_top_fixes/t/72pg.t 2009-07-03 10:47:57 UTC (rev 6962)
@@ -144,7 +144,9 @@
is_deeply($type_info, $test_type_info,
'columns_info_for - column data types');
-{
+SKIP: {
+ skip "Need DBD::Pg 2.9.2 or newer for array tests", 4 if $DBD::Pg::VERSION < 2.009002;
+
lives_ok {
$schema->resultset('ArrayTest')->create({
arrayfield => [1, 2],
Modified: DBIx-Class/0.08/branches/mssql_top_fixes/t/from_subquery.t
===================================================================
--- DBIx-Class/0.08/branches/mssql_top_fixes/t/from_subquery.t 2009-07-03 10:06:57 UTC (rev 6961)
+++ DBIx-Class/0.08/branches/mssql_top_fixes/t/from_subquery.t 2009-07-03 10:47:57 UTC (rev 6962)
@@ -3,17 +3,12 @@
use Test::More;
-BEGIN {
- eval "use SQL::Abstract 1.49";
- plan $@
- ? ( skip_all => "Needs SQLA 1.49+" )
- : ( tests => 8 );
-}
-
use lib qw(t/lib);
use DBICTest;
use DBIC::SqlMakerTest;
+plan tests => 8;
+
my $schema = DBICTest->init_schema();
my $art_rs = $schema->resultset('Artist');
my $cdrs = $schema->resultset('CD');
More information about the Bast-commits
mailing list