From: Peter Rabbitson Date: Fri, 12 Feb 2010 12:52:55 +0000 (+0000) Subject: Merge 'trunk' into 'dephandling' X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=30da837490e110a19eeab063d7a94440502a07b1;p=dbsrgits%2FDBIx-Class-Historic.git Merge 'trunk' into 'dephandling' r8628@Thesaurus (orig r8615): caelum | 2010-02-11 11:35:01 +0100 r21090@hlagh (orig r7836): caelum | 2009-11-02 06:40:52 -0500 new branch to fix unhandled methods in Storage::DBI::Replicated r21091@hlagh (orig r7837): caelum | 2009-11-02 06:42:00 -0500 add test to display unhandled methods r21092@hlagh (orig r7838): caelum | 2009-11-02 06:55:34 -0500 minor fix to last committed test r21093@hlagh (orig r7839): caelum | 2009-11-02 09:26:00 -0500 minor test code cleanup r23125@hlagh (orig r8607): caelum | 2010-02-10 19:25:51 -0500 add unimplemented Storage::DBI methods to ::DBI::Replicated r23130@hlagh (orig r8612): ribasushi | 2010-02-11 05:12:48 -0500 Podtesting exclusion r8630@Thesaurus (orig r8617): frew | 2010-02-11 11:45:54 +0100 Changes (from a while ago) r8631@Thesaurus (orig r8618): caelum | 2010-02-11 11:46:58 +0100 savepoints for SQLAnywhere r8640@Thesaurus (orig r8627): ribasushi | 2010-02-11 12:33:19 +0100 r8424@Thesaurus (orig r8411): ribasushi | 2010-01-22 11:19:40 +0100 Chaining POC test r8641@Thesaurus (orig r8628): ribasushi | 2010-02-11 12:34:19 +0100 r8426@Thesaurus (orig r8413): ribasushi | 2010-01-22 11:35:15 +0100 Moev failing regression test away from trunk r8642@Thesaurus (orig r8629): ribasushi | 2010-02-11 12:34:56 +0100 r8643@Thesaurus (orig r8630): ribasushi | 2010-02-11 12:35:03 +0100 r8507@Thesaurus (orig r8494): frew | 2010-02-01 04:33:08 +0100 small refactor to put select/as/+select/+as etc merging in it's own function r8644@Thesaurus (orig r8631): ribasushi | 2010-02-11 12:35:11 +0100 r8514@Thesaurus (orig r8501): frew | 2010-02-02 05:12:29 +0100 revert actual changes from yesterday as per ribasushis advice r8645@Thesaurus (orig r8632): ribasushi | 2010-02-11 12:35:16 +0100 r8522@Thesaurus (orig r8509): frew | 2010-02-02 19:39:33 +0100 delete +stuff if stuff exists r8646@Thesaurus (orig r8633): ribasushi | 2010-02-11 12:35:23 +0100 r8534@Thesaurus (orig r8521): frew | 2010-02-03 06:14:44 +0100 change deletion/overriding to fix t/76 r8647@Thesaurus (orig r8634): ribasushi | 2010-02-11 12:35:30 +0100 r8535@Thesaurus (orig r8522): frew | 2010-02-03 06:57:15 +0100 some basic readability factorings (aka, fewer nested ternaries and long maps) r8648@Thesaurus (orig r8635): ribasushi | 2010-02-11 12:36:01 +0100 r8558@Thesaurus (orig r8545): frew | 2010-02-04 20:32:54 +0100 fix incorrect test in t/76select.t and posit an incorrect solution r8649@Thesaurus (orig r8636): ribasushi | 2010-02-11 12:38:47 +0100 r8650@Thesaurus (orig r8637): ribasushi | 2010-02-11 12:38:57 +0100 r8578@Thesaurus (orig r8565): ribasushi | 2010-02-05 19:11:09 +0100 Should not be needed r8651@Thesaurus (orig r8638): ribasushi | 2010-02-11 12:39:03 +0100 r8579@Thesaurus (orig r8566): ribasushi | 2010-02-05 19:13:24 +0100 SQLA now fixed r8652@Thesaurus (orig r8639): ribasushi | 2010-02-11 12:39:10 +0100 r8624@Thesaurus (orig r8611): ribasushi | 2010-02-11 10:31:08 +0100 MOAR testing r8653@Thesaurus (orig r8640): ribasushi | 2010-02-11 12:39:17 +0100 r8626@Thesaurus (orig r8613): frew | 2010-02-11 11:16:30 +0100 fix bad test r8654@Thesaurus (orig r8641): ribasushi | 2010-02-11 12:39:23 +0100 r8627@Thesaurus (orig r8614): frew | 2010-02-11 11:21:52 +0100 fix t/76, break rsc tests r8655@Thesaurus (orig r8642): ribasushi | 2010-02-11 12:39:30 +0100 r8632@Thesaurus (orig r8619): frew | 2010-02-11 11:53:50 +0100 fix incorrect test r8656@Thesaurus (orig r8643): ribasushi | 2010-02-11 12:39:35 +0100 r8633@Thesaurus (orig r8620): frew | 2010-02-11 11:54:49 +0100 make t/76s and t/88 pass by deleting from the correct attr hash r8657@Thesaurus (orig r8644): ribasushi | 2010-02-11 12:39:40 +0100 r8634@Thesaurus (orig r8621): frew | 2010-02-11 11:55:41 +0100 fix a test due to ordering issues r8658@Thesaurus (orig r8645): ribasushi | 2010-02-11 12:39:45 +0100 r8635@Thesaurus (orig r8622): frew | 2010-02-11 11:58:23 +0100 this is why you run tests before you commit them. r8659@Thesaurus (orig r8646): ribasushi | 2010-02-11 12:39:51 +0100 r8636@Thesaurus (orig r8623): frew | 2010-02-11 12:00:59 +0100 fix another ordering issue r8660@Thesaurus (orig r8647): ribasushi | 2010-02-11 12:39:57 +0100 r8637@Thesaurus (orig r8624): frew | 2010-02-11 12:11:31 +0100 fix for search/select_chains r8661@Thesaurus (orig r8648): ribasushi | 2010-02-11 12:40:03 +0100 r8662@Thesaurus (orig r8649): caelum | 2010-02-11 12:40:07 +0100 test nanosecond precision for SQLAnywhere r8663@Thesaurus (orig r8650): ribasushi | 2010-02-11 12:40:09 +0100 r8639@Thesaurus (orig r8626): ribasushi | 2010-02-11 12:33:03 +0100 Changes and small ommission r8666@Thesaurus (orig r8653): ribasushi | 2010-02-11 18:16:45 +0100 Changes r8674@Thesaurus (orig r8661): ribasushi | 2010-02-12 09:12:45 +0100 Fix moose dep --- 30da837490e110a19eeab063d7a94440502a07b1 diff --cc Makefile.PL index 2d7349e,ea56856..fad5ce5 --- a/Makefile.PL +++ b/Makefile.PL @@@ -12,104 -11,130 +12,104 @@@ name 'DBIx-Class' perl_version '5.008001'; all_from 'lib/DBIx/Class.pm'; +my $build_requires = { - 'DBD::SQLite' => '1.25', ++ 'DBD::SQLite' => '1.25', +}; + +my $test_requires = { - 'File::Temp' => '0.22', - 'Test::Builder' => '0.33', - 'Test::Deep' => '0', - 'Test::Exception' => '0', - 'Test::More' => '0.92', - 'Test::Warn' => '0.21', ++ 'File::Temp' => '0.22', ++ 'Test::Builder' => '0.33', ++ 'Test::Deep' => '0', ++ 'Test::Exception' => '0', ++ 'Test::More' => '0.92', ++ 'Test::Warn' => '0.21', +}; + +my $runtime_requires = { + # Core + 'List::Util' => '0', + 'Scalar::Util' => '0', + 'Storable' => '0', + + # Dependencies + 'Carp::Clan' => '6.0', + 'Class::Accessor::Grouped' => '0.09002', + 'Class::C3::Componentised' => '1.0005', + 'Class::Inspector' => '1.24', + 'Data::Page' => '2.00', + 'DBI' => '1.609', + 'JSON::Any' => '1.18', + 'MRO::Compat' => '0.09', + 'Module::Find' => '0.06', + 'Path::Class' => '0.16', + 'Scope::Guard' => '0.03', + 'SQL::Abstract' => '1.61', + 'SQL::Abstract::Limit' => '0.13', + 'Sub::Name' => '0.04', + 'Data::Dumper::Concise' => '1.000', +}; + +# this is so we can order requires alphabetically +# copies are needed for author requires injection +my $reqs = { + build_requires => { %$build_requires }, + requires => { %$runtime_requires }, + test_requires => { %$test_requires }, +}; -test_requires 'Test::Builder' => '0.33'; -test_requires 'Test::Deep' => '0'; -test_requires 'Test::Exception' => '0'; -test_requires 'Test::More' => '0.92'; -test_requires 'Test::Warn' => '0.21'; - -test_requires 'File::Temp' => '0.22'; - - -# Core -requires 'List::Util' => '0'; -requires 'Scalar::Util' => '0'; -requires 'Storable' => '0'; - -# Dependencies (keep in alphabetical order) -requires 'Carp::Clan' => '6.0'; -requires 'Class::Accessor::Grouped' => '0.09002'; -requires 'Class::C3::Componentised' => '1.0005'; -requires 'Class::Inspector' => '1.24'; -requires 'Data::Page' => '2.00'; -requires 'DBD::SQLite' => '1.25'; -requires 'DBI' => '1.609'; -requires 'JSON::Any' => '1.18'; -requires 'MRO::Compat' => '0.09'; -requires 'Module::Find' => '0.06'; -requires 'Path::Class' => '0.16'; -requires 'Scope::Guard' => '0.03'; -requires 'SQL::Abstract' => '1.61'; -requires 'SQL::Abstract::Limit' => '0.13'; -requires 'Sub::Name' => '0.04'; -requires 'Data::Dumper::Concise' => '1.000'; - -my %replication_requires = ( - 'Moose', => '0.98', - 'MooseX::Types', => '0.21', - 'namespace::clean' => '0.11', - 'Hash::Merge', => '0.11', -); - -#************************************************************************# -# Make *ABSOLUTELY SURE* that nothing on this list is a real require, # -# since every module listed in %force_requires_if_author is deleted # -# from the final META.yml (thus will never make it as a CPAN dependency) # -#************************************************************************# -my %force_requires_if_author = ( - %replication_requires, - - # when changing also adjust $DBIx::Class::Storage::DBI::minimum_sqlt_version - 'SQL::Translator' => '0.11002', - -# 'Module::Install::Pod::Inherit' => '0.01', - - # when changing also adjust version in t/02pod.t - 'Test::Pod' => '1.26', - - # when changing also adjust version in t/06notabs.t -# 'Test::NoTabs' => '0.9', - - # when changing also adjust version in t/07eol.t -# 'Test::EOL' => '0.6', - - # when changing also adjust version in t/03podcoverage.t - 'Test::Pod::Coverage' => '1.08', - 'Pod::Coverage' => '0.20', - - # CDBI-compat related - 'DBIx::ContextualFetch' => '0', - 'Class::DBI::Plugin::DeepAbstractSearch' => '0', - 'Class::Trigger' => '0', - 'Time::Piece::MySQL' => '0', - 'Clone' => '0', - 'Date::Simple' => '3.03', - - # t/52cycle.t - 'Test::Memory::Cycle' => '0', - 'Devel::Cycle' => '1.10', - - # t/36datetime.t - # t/60core.t - 'DateTime::Format::SQLite' => '0', - - # t/96_is_deteministic_value.t - 'DateTime::Format::Strptime'=> '0', - - # database-dependent reqs - # - $ENV{DBICTEST_PG_DSN} - ? ( - 'Sys::SigAction' => '0', - 'DBD::Pg' => '2.009002', - 'DateTime::Format::Pg' => '0', - ) : () - , - - $ENV{DBICTEST_MYSQL_DSN} - ? ( - 'DateTime::Format::MySQL' => '0', - ) : () - , - - $ENV{DBICTEST_ORA_DSN} - ? ( - 'DateTime::Format::Oracle' => '0', - ) : () - , - - $ENV{DBICTEST_SYBASE_DSN} - ? ( - 'DateTime::Format::Sybase' => 0, - ) : () - , - grep $_, @ENV{qw/DBICTEST_SYBASE_ASA_DSN DBICTEST_SYBASE_ASA_ODBC_DSN/} - ? ( - 'DateTime::Format::Strptime' => 0, - ) : () - , -); -#************************************************************************# -# Make ABSOLUTELY SURE that nothing on the list above is a real require, # -# since every module listed in %force_requires_if_author is deleted # -# from the final META.yml (thus will never make it as a CPAN dependency) # -#************************************************************************# +# re-build README and require extra modules for testing if we're in a checkout +if ($Module::Install::AUTHOR) { + + print "Regenerating README\n"; + system('pod2text lib/DBIx/Class.pm > README'); + + if (-f 'MANIFEST') { + print "Removing MANIFEST\n"; + unlink 'MANIFEST'; + } +# FIXME Disabled due to unsolved issues, ask theorbtwo +# require Module::Install::Pod::Inherit; +# PodInherit(); + + warn <<'EOW'; +****************************************************************************** +****************************************************************************** +*** *** +*** AUTHOR MODE: all optional test dependencies converted to hard requires *** +*** *** +****************************************************************************** +****************************************************************************** + +EOW + + require DBIx::Class::Optional::Dependencies; + $reqs->{test_requires} = { + %{$reqs->{test_requires}}, + %{DBIx::Class::Optional::Dependencies->all_optional_requirements}, + }; +} + +# compose final req list, for alphabetical ordering +my %final_req; +for my $rtype (keys %$reqs) { + for my $mod (keys %{$reqs->{$rtype}} ) { + + # sanity check req duplications + if ($final_req{$mod}) { + die "$mod specified as both a $rtype and a $final_req{$mod}[1]\n"; + } + + $final_req{$mod} = [ $rtype, $reqs->{$rtype}{$mod}||0 ], + } +} + +# actual require +for my $mod (sort keys %final_req) { + my ($rtype, $ver) = @{$final_req{$mod}}; + no strict 'refs'; + $rtype->($mod, $ver); +} install_script (qw| script/dbicadmin