From: Brandon Black Date: Wed, 26 Jul 2006 00:18:30 +0000 (+0000) Subject: 0.03006 - fix columns_info_for interaction X-Git-Tag: 0.03006 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=520107ef3685818201308dd35958e2dfd1c7c5a2;p=dbsrgits%2FDBIx-Class-Schema-Loader.git 0.03006 - fix columns_info_for interaction --- diff --git a/Changes b/Changes index 9ffc050..cb8d62e 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,8 @@ Revision history for Perl extension DBIx::Class::Schema::Loader +0.03006 Wed Jul 26 00:14:58 UTC 2006 + - Fixed column-case issue w/ columns_info_for + 0.03005 Wed Jul 19 15:09:30 UTC 2006 [ Pretty much everything in this release originates from nilsonsfj patches ] - bugfix: mysql unique constraint code had an diff --git a/MANIFEST.SKIP b/MANIFEST.SKIP index c57453e..84c323a 100644 --- a/MANIFEST.SKIP +++ b/MANIFEST.SKIP @@ -32,6 +32,9 @@ # Don't ship the test junk ^t/_dump ^t/dbictest.db +^t/dbictest.db-journal +^t/sqlite.test +^t/sqlite.test-journal # Don't ship the last dist we built :) \.tar\.gz$ diff --git a/lib/DBIx/Class/Schema/Loader.pm b/lib/DBIx/Class/Schema/Loader.pm index f54c5a7..bd2f8df 100644 --- a/lib/DBIx/Class/Schema/Loader.pm +++ b/lib/DBIx/Class/Schema/Loader.pm @@ -12,7 +12,7 @@ use Scalar::Util qw/ weaken /; # Always remember to do all digits for the version even if they're 0 # i.e. first release of 0.XX *must* be 0.XX000. This avoids fBSD ports # brain damage and presumably various other packaging systems too -our $VERSION = '0.03005'; +our $VERSION = '0.03006'; __PACKAGE__->mk_classaccessor('dump_to_dir'); __PACKAGE__->mk_classaccessor('loader'); diff --git a/lib/DBIx/Class/Schema/Loader/Base.pm b/lib/DBIx/Class/Schema/Loader/Base.pm index 00c0c2b..c786457 100644 --- a/lib/DBIx/Class/Schema/Loader/Base.pm +++ b/lib/DBIx/Class/Schema/Loader/Base.pm @@ -493,10 +493,11 @@ sub _load_classes { $self->_dbic_stmt($table_class,'add_columns',@$cols); } else { + my %col_info_lc = map { lc($_), $col_info->{$_} } keys %$col_info; $self->_dbic_stmt( $table_class, 'add_columns', - map { $_, $col_info->{$_} } @$cols + map { $_, ($col_info_lc{$_}||{}) } @$cols ); } diff --git a/t/22dump.t b/t/22dump.t index 19efcbc..5d32c90 100644 --- a/t/22dump.t +++ b/t/22dump.t @@ -27,7 +27,7 @@ my $dump_path = './t/_dump'; plan tests => 8; -rmtree($dump_path, 1, 0711); +rmtree($dump_path, 1, 1); eval { DBICTest::Schema::1->connect($make_dbictest_db::dsn) }; ok(!$@, 'no death with dump_directory set') or diag "Dump failed: $@"; @@ -47,7 +47,7 @@ my @warnings_regexes = ( like(shift @warn_output, $_) foreach (@warnings_regexes); -rmtree($dump_path, 1, 0711); +rmtree($dump_path, 1, 1); eval { DBICTest::Schema::2->connect($make_dbictest_db::dsn) }; ok(!$@, 'no death with dump_directory set (overwrite1)')