12 years agoremove dependency on File::Slurp
Rafael Kitover [Wed, 28 Sep 2011 19:31:02 +0000]
remove dependency on File::Slurp

The current version of File::Slurp has a "use 5.6.2;" statement. This
throws a warning on perl 5.10.0 which breaks some of our tests. The
statement should be "use 5.006002;".

My attempts to contact the author, Uri Guttman were not successful.

As we have our own convenience method 'slurp_file' in ::Utils now, there
is little need to depend on File::Slurp anymore anyway.

For these reasons the dependency has been removed.

12 years agoallow constraint/exclude options together
Brian Phillips [Wed, 28 Sep 2011 16:21:25 +0000]
allow constraint/exclude options together

12 years agofix t/backcompat/0.04006 tests
Rafael Kitover [Sat, 24 Sep 2011 19:28:04 +0000]
fix t/backcompat/0.04006 tests

The Oracle driver no longer lowercases table names from the catalog, and
these names are normalized to upper case. The main common tests alias
the lowercase table names for the monikers and classes hashes for this
case; this commit adds the same code to the t/backcompat/0.04006 common
tests (in lib/dbixcsl_common_tests.pm .)

12 years agofix preserve_case tests in common tests
Rafael Kitover [Sat, 24 Sep 2011 14:05:22 +0000]
fix preserve_case tests in common tests

Rescans with preserve_case option reset to the original value after
doing a rescan with preserve_case set to 1 and running the preserve_case
tests.

Failure to do so was breaking the Oracle extra tests.

12 years agoFix the failing pg tests (unicode wasn't slurped)
Peter Rabbitson [Wed, 7 Sep 2011 19:27:00 +0000]
Fix the failing pg tests (unicode wasn't slurped)

12 years agofix backcompat
Rafael Kitover [Wed, 7 Sep 2011 11:07:26 +0000]
fix backcompat

Fixes generating the old moniker when upgrading from a previous code
version (v4 unsingularized monikers -> singularized.)

t/25backcompat.t passes again.

12 years agofix uninit warn for no pod and result_base_class
Rafael Kitover [Tue, 6 Sep 2011 08:21:41 +0000]
fix uninit warn for no pod and result_base_class

12 years agofix multiple DEFAULT NULLs
Rafael Kitover [Tue, 6 Sep 2011 08:16:11 +0000]
fix multiple DEFAULT NULLs

    $info->{default_value} = \'null'

is unsafe because Data::Dump optimizes
refs to constants, so we must make sure to use:

    my $null = 'null';
    $info->{default_value} = \$null;

for all scalar refs in the dump.

12 years agofix defaults broken by last Pg defaults fix commit
Rafael Kitover [Tue, 6 Sep 2011 07:44:10 +0000]
fix defaults broken by last Pg defaults fix commit

12 years agoupdate Changes with Pg defaults fixes
Rafael Kitover [Tue, 6 Sep 2011 07:23:04 +0000]
update Changes with Pg defaults fixes

12 years agoimprove Pg default handling
Rafael Kitover [Tue, 6 Sep 2011 07:18:58 +0000]
improve Pg default handling

Correctly handles these cases:
 - <type> DEFAULT NULL
 - boolean DEFAULT 0::boolean

12 years agosort unique constraints
Rafael Kitover [Thu, 18 Aug 2011 20:55:09 +0000]
sort unique constraints

Relationships and unique constraints are now sorted by name in the
Result files to cut down on pointless diff spam in version control.

This commit also adds checking for the SCHEMA_LOADER_TESTS_NOCLEANUP
environment variable when removing the test sqlite DBs used by various
tests, this allows for inspecting them with the sqlite3 shell.

12 years agomulti db_schema support
Rafael Kitover [Mon, 30 May 2011 20:01:46 +0000]
multi db_schema support

Allows putting multiple schemas or databases and schemas into the
db_schema option. Supports cross-schema foreign keys where available. On
Sybase ASE, MSSQL and Informix multiple databases as well as schemas are
supported (but only Sybase ASE allows cross-database foreign keys.)

Adds the moniker_parts option for resolving name clashes when using
multiple schemas that have tables with the same name.

Table names are now represented by the ::Table class (all the code for
which is in the ::DBObject superclass.) There is also ::Table::Sybase
for Sybase ASE and MSSQL as well as ::Table::Informix for Informix. In
the future other database objects such as sequences may use the
::DBObject class.

Currently there are extra tests for objects in separate schemas and
cross-schema relationships for each database separately, these may later
be merged into the common tests in some fashion.

All database backends are up to date with respect to their capabilities
for fully qualified table names, with some exceptions.

 - no support for dblinks in Oracle
 - no support for serverlinks in MSSQL
 - no support for databases attached as namespaces in SQLite

For SQLite, Firebird and MS Access it is possible to pass a single
db_schema and have DBIC names qualified with it, but this capability is
primarily for testing and deployment.

12 years agosilence comment tests
Rafael Kitover [Wed, 10 Aug 2011 08:58:14 +0000]
silence comment tests

Adds quiet => 1 to loader_options for the comment tests to disable the
"Dumping manual schema..." warnings.

12 years agoupdate Changes with dbicdump config file support
Rafael Kitover [Wed, 10 Aug 2011 08:47:26 +0000]
update Changes with dbicdump config file support

12 years agoopt deps for dbicdump config and test
Rafael Kitover [Sun, 7 Aug 2011 12:57:12 +0000]
opt deps for dbicdump config and test

Adds Config::Any to dbicdump_config group in ::Optional::Dependencies
and Config::Any with Config::General to the test_dbicdump_config group.

Adds t/60dbicdump_config.t test for using a config file with dbicdump.

12 years agoconfig file support for dbicdump script
Al Newkirk [Tue, 26 Jul 2011 07:39:52 +0000]
config file support for dbicdump script

Changes dbicdump so that if only one parameter is given it is used as
the config file loaded with Config::Any. The config file must have the
keys schema_class and connect_info, and optionally loader_options.

12 years agopigs don't fly, they just roll around in shit
Rafael Kitover [Fri, 5 Aug 2011 08:44:15 +0000]
pigs don't fly, they just roll around in shit

Revert commit f1740f1b11e070f4e794fa43c606323d3ef528ab.

12 years agosome changes to filter code
Rafael Kitover [Fri, 5 Aug 2011 06:34:28 +0000]
some changes to filter code

Renames filter_generated_text => filter_generated_code.

Changes the filter coderef signature to take the type of file being
filtered, 'schema' or 'result'.

Adds support for setting the option to a string which is used as an
external filter program.

Updates Changes.

12 years agoadds the ability to filter generated code
Ben Tilly [Wed, 3 Aug 2011 23:24:25 +0000]
adds the ability to filter generated code

Adds the filter_generated_text option which takes a coderef for
filtering the generated code. The coderef takes the class and code as
parameters.

12 years agoflying pigs. almost as likely as win32 doing what you wanted it to.
Matt S Trout [Tue, 2 Aug 2011 13:05:43 +0000]
flying pigs. almost as likely as win32 doing what you wanted it to.

12 years agominor changes to table/column comment code
Rafael Kitover [Tue, 2 Aug 2011 10:07:38 +0000]
minor changes to table/column comment code

Updates Changes.

Mentions Oracle support in generate_pod POD in ::Loader::Base.

Adds checking for generic comments via ->next::method in ::DBI::Oracle
as well.

Wraps table/column comment queries for MySQL on information_schema in
try blocks, as not all versions of MySQL have information_schema (5.0+
 do.)

Changes MySQL comment tests to use the new slurp_file util.

Makes the test messages in t/30_*.t more clear.

12 years agogeneric comments mechanism, MySQL specific support
Ben Tilly [Fri, 22 Jul 2011 23:03:34 +0000]
generic comments mechanism, MySQL specific support

Adds support for the table_comments and column_comments tables, which
override the db-specific metadata comment support in ::Loader::DBI.

Documents these tables in ::Loader::Base .

Also adds support for MySQL table and column comments from
information_schema.

12 years agofucking pigs broke my Win32 perl
Rafael Kitover [Mon, 25 Jul 2011 19:28:28 +0000]
fucking pigs broke my Win32 perl

The fucking pigs did something to my Win32 perl so that command line
args with special characters like [] and {} are not parsed correctly.
This problem does not show up for CPAN testers running these tests,
t/23dumpmore.t and t/26dump_use_moose.t .

This commit adds a check for refs in loader options or connect_info in
the t/lib/dbixcsl_dumper_tests.pm test lib, and skips tests on Win32 if
the FUCKING_PIGS environment variable is set.

12 years agosupport alternate line endings
Rafael Kitover [Mon, 25 Jul 2011 13:02:55 +0000]
support alternate line endings

Adds a utility method slurp_file to ::Utils for reading files in UTF-8
and converting the CRLFs or LFs inside to the platform \n. Changes all
uses of File::Slurp::read_file to slurp_file and changes some regexes to
match \r? at line ends.

12 years agofix t/10_11msaccess_common.t on non-Win32
Rafael Kitover [Sun, 24 Jul 2011 17:04:15 +0000]
fix t/10_11msaccess_common.t on non-Win32

Changes a "use Win32::OLE" to a require where needed.

12 years agofix backcompat tests
Rafael Kitover [Sun, 24 Jul 2011 16:30:17 +0000]
fix backcompat tests

Updates the RelBuilder classes to take into account that
->_inflect_singular and ->_inflect_plural return a list instead of a
scalar now.

12 years agoadd quiet option
Rafael Kitover [Sun, 24 Jul 2011 05:23:03 +0000]
add quiet option

Also adds some improvements to the t/lib/dbixcsl_dumper_tests.pm test
library:

- list warnings if warning count doesn't match

- fixes undefined warning if there are more expected warnings than
  received warnings

12 years agomake $schema->loader a public method
Rafael Kitover [Sat, 23 Jul 2011 18:15:44 +0000]
make $schema->loader a public method

Also adds some TODO entries, adds Task::Weaken to dependencies and
removes a duplicate dependency on List::MoreUtils.

12 years agoRemoving these files from master because they are not for the next release.
Ben Tilly [Sat, 9 Jul 2011 19:19:03 +0000]
Removing these files from master because they are not for the next release.

I will recreate them on a branch, as I originally intended to.

12 years agoAdd failing test for feature I want.
Ben Tilly [Thu, 7 Jul 2011 23:46:55 +0000]
Add failing test for feature I want.

12 years agoadd schema_components option
Rafael Kitover [Tue, 5 Jul 2011 09:30:55 +0000]
add schema_components option

12 years agosort relationships
Rafael Kitover [Tue, 5 Jul 2011 08:00:05 +0000]
sort relationships

12 years agobetter option validation for result_component_map, result_role_map and rel_collision_map
Rafael Kitover [Fri, 3 Jun 2011 21:24:55 +0000]
better option validation for result_component_map, result_role_map and rel_collision_map

12 years agoadd handle for Ben Tilly in CONTRIBUTORS
Rafael Kitover [Tue, 14 Jun 2011 14:53:55 +0000]
add handle for Ben Tilly in CONTRIBUTORS

12 years agoadd rel_name_map option
Rafael Kitover [Tue, 14 Jun 2011 04:37:54 +0000]
add rel_name_map option

12 years agofix syntax error in common tests
Rafael Kitover [Fri, 10 Jun 2011 17:37:16 +0000]
fix syntax error in common tests

12 years agofix the decimal data type for MS Access over ODBC
Rafael Kitover [Fri, 10 Jun 2011 16:54:56 +0000]
fix the decimal data type for MS Access over ODBC

12 years agohandle MySQL enums/sets containing elements with single quotes
Rafael Kitover [Fri, 10 Jun 2011 14:24:08 +0000]
handle MySQL enums/sets containing elements with single quotes

12 years agoanother enum test for MySQL
Rafael Kitover [Fri, 10 Jun 2011 10:52:55 +0000]
another enum test for MySQL

12 years agofix enum/set detection for MySQL (RT#68717)
Rafael Kitover [Fri, 10 Jun 2011 04:55:58 +0000]
fix enum/set detection for MySQL (RT#68717)

12 years agodocument dumping a remote host
Caleb Cushing [Thu, 9 Jun 2011 21:07:20 +0000]
document dumping a remote host

Signed-off-by: Caleb Cushing <xenoterracide@gmail.com>

12 years agofix is_nullable detection on MS Access
Rafael Kitover [Thu, 9 Jun 2011 13:44:50 +0000]
fix is_nullable detection on MS Access

12 years agofix POD for scalarref tables
Rafael Kitover [Tue, 7 Jun 2011 08:44:02 +0000]
fix POD for scalarref tables

12 years agofix backcompat tests
Rafael Kitover [Tue, 7 Jun 2011 07:55:46 +0000]
fix backcompat tests

12 years agofix uniq_to_primary test on DB2 and SQLAnywhere
Rafael Kitover [Tue, 7 Jun 2011 07:49:52 +0000]
fix uniq_to_primary test on DB2 and SQLAnywhere

12 years agoimprove uniq_to_primary test
Rafael Kitover [Tue, 7 Jun 2011 06:02:22 +0000]
improve uniq_to_primary test

12 years agoonly promote uniqs with non-nullable columns to pks
Rafael Kitover [Mon, 6 Jun 2011 10:37:11 +0000]
only promote uniqs with non-nullable columns to pks

12 years agorun col_accessor_map tests with skip_rels too
Rafael Kitover [Fri, 3 Jun 2011 20:22:35 +0000]
run col_accessor_map tests with skip_rels too

12 years agoupdate Changes
Rafael Kitover [Wed, 1 Jun 2011 04:43:25 +0000]
update Changes

12 years agofix test counts, cleanup new test table
Rafael Kitover [Mon, 30 May 2011 20:05:15 +0000]
fix test counts, cleanup new test table

12 years agoadded uniq_to_primary option to promote unique keys to primary keys (RT#25944)
Rafael Kitover [Mon, 30 May 2011 15:29:23 +0000]
added uniq_to_primary option to promote unique keys to primary keys (RT#25944)

12 years agoreset _uniqs_started for POD on rescan
Rafael Kitover [Mon, 30 May 2011 14:23:26 +0000]
reset _uniqs_started for POD on rescan

12 years agogenerate POD for unique constraints, set_primary_key and table
Rafael Kitover [Mon, 30 May 2011 14:08:11 +0000]
generate POD for unique constraints, set_primary_key and table

12 years agofix t/backcompat/0.04006/23dumpmore.t
Rafael Kitover [Sun, 29 May 2011 21:12:04 +0000]
fix t/backcompat/0.04006/23dumpmore.t

12 years agofix Oracle
Rafael Kitover [Sun, 29 May 2011 20:38:50 +0000]
fix Oracle

12 years agofix t/23dumpmore.t
Rafael Kitover [Sun, 29 May 2011 20:36:12 +0000]
fix t/23dumpmore.t

12 years agosupport arrayrefs for result_namespace and resultset_namespace (RT#40214)
Rafael Kitover [Sun, 29 May 2011 15:49:47 +0000]
support arrayrefs for result_namespace and resultset_namespace (RT#40214)

12 years agofix clasing test dbs
Rafael Kitover [Sun, 29 May 2011 13:34:35 +0000]
fix clasing test dbs

12 years agofixup POD
Rafael Kitover [Sat, 28 May 2011 20:20:36 +0000]
fixup POD

12 years agoadd more naming options
Rafael Kitover [Sat, 28 May 2011 15:04:23 +0000]
add more naming options

12 years agofix warning, fix test counts
Rafael Kitover [Sat, 28 May 2011 01:46:05 +0000]
fix warning, fix test counts

12 years agorun the preserve rel name test on MySQL too
Rafael Kitover [Sat, 28 May 2011 00:40:42 +0000]
run the preserve rel name test on MySQL too

12 years agosupport quoted PostgreSQL schema names with special chars (RT#64766)
Rafael Kitover [Fri, 27 May 2011 14:50:17 +0000]
support quoted PostgreSQL schema names with special chars (RT#64766)

12 years agoautomatically turn on quoting for MySQL (RT#60469)
Rafael Kitover [Thu, 26 May 2011 20:54:46 +0000]
automatically turn on quoting for MySQL (RT#60469)

12 years agobecome utf8-aware (RT#67920)
Rafael Kitover [Thu, 26 May 2011 19:50:56 +0000]
become utf8-aware (RT#67920)

12 years agocheck for relname accessor collisions on duplicate disambiguation
Rafael Kitover [Thu, 26 May 2011 13:48:08 +0000]
check for relname accessor collisions on duplicate disambiguation

12 years agoworkaround for common tests for MySQL on Win32
Rafael Kitover [Thu, 26 May 2011 04:26:12 +0000]
workaround for common tests for MySQL on Win32

12 years agohandle duplicate relationship names (RT#64041)
Rafael Kitover [Wed, 18 May 2011 02:24:16 +0000]
handle duplicate relationship names (RT#64041)

12 years agoRevert "set cascade_update => 0 on might_have relationships"
Rafael Kitover [Tue, 24 May 2011 15:24:33 +0000]
Revert "set cascade_update => 0 on might_have relationships"

This reverts commit 9b1dd93554ec8f70923940e2ae88e2e0260d0b55.

12 years agoset cascade_update => 0 on might_have relationships
Rafael Kitover [Tue, 24 May 2011 15:15:28 +0000]
set cascade_update => 0 on might_have relationships

12 years agochange a couple references in Base POD to links
Rafael Kitover [Fri, 20 May 2011 10:26:44 +0000]
change a couple references in Base POD to links

12 years agoFixed typo in S::L::Base POD
Mark A. Stratman [Thu, 19 May 2011 14:46:51 +0000]
Fixed typo in S::L::Base POD

12 years agoadd asterisks to items in POD class lists
Rafael Kitover [Wed, 18 May 2011 02:30:05 +0000]
add asterisks to items in POD class lists

12 years agogenerate POD for result_base_class as well
Rafael Kitover [Tue, 17 May 2011 21:02:24 +0000]
generate POD for result_base_class as well

12 years agogenerate POD for additional_classes, additional_base_classes, left_base_classes,...
Rafael Kitover [Tue, 17 May 2011 20:34:38 +0000]
generate POD for additional_classes, additional_base_classes, left_base_classes, components, result_components_map, result_roles and result_roles_map

12 years agomove roles to the end of the generated class so that "requires" works with columns...
Rafael Kitover [Tue, 17 May 2011 18:59:41 +0000]
move roles to the end of the generated class so that "requires" works with columns/rels

12 years agoadd an extra symbol to the rt59849 test
Rafael Kitover [Tue, 17 May 2011 18:43:19 +0000]
add an extra symbol to the rt59849 test

12 years agofix CONTRIBUTORS
Rafael Kitover [Tue, 17 May 2011 18:41:01 +0000]
fix CONTRIBUTORS

12 years agosupport ->use_namespaces(0) in Loader.pm, fix tests for new dynamic schema behavior
Rafael Kitover [Mon, 16 May 2011 14:44:12 +0000]
support ->use_namespaces(0) in Loader.pm, fix tests for new dynamic schema behavior

12 years agologic fail in naming_set check
Rafael Kitover [Mon, 16 May 2011 13:50:14 +0000]
logic fail in naming_set check

12 years agonaming_set went into the readonly accessor group by accident, fixed
Rafael Kitover [Mon, 16 May 2011 13:21:56 +0000]
naming_set went into the readonly accessor group by accident, fixed

12 years agoonly set use_namespaces=1 if naming is set for dynamic schemas
Rafael Kitover [Mon, 16 May 2011 13:13:04 +0000]
only set use_namespaces=1 if naming is set for dynamic schemas

12 years agoadded result_roles and result_roles_map options, fixed a bug with accessor collision...
Mark A. Stratman [Fri, 13 May 2011 17:57:42 +0000]
added result_roles and result_roles_map options, fixed a bug with accessor collision detection from result_components_map components, fixed some common tests

12 years agorename t/50addl_base_classes.t from Mark Hedges to t/50rt59849.t
Rafael Kitover [Mon, 16 May 2011 09:34:07 +0000]
rename t/50addl_base_classes.t from Mark Hedges to t/50rt59849.t

12 years agohandle "use warnings FATAL => 'all' and set use_namespaces=1 for dynamic schemas...
Rafael Kitover [Mon, 16 May 2011 08:00:38 +0000]
handle "use warnings FATAL => 'all' and set use_namespaces=1 for dynamic schemas not in backcompat mode (RT#59849)

13 years agofix mysql rel detection for mixed-case tables on mixed-case filesystems
Rafael Kitover [Thu, 12 May 2011 09:48:29 +0000]
fix mysql rel detection for mixed-case tables on mixed-case filesystems

13 years agosupport for unicode Firebird data types
Rafael Kitover [Thu, 21 Apr 2011 02:22:39 +0000]
support for unicode Firebird data types

13 years agomove Firebird ODBC driver ->type_info override into driver
Rafael Kitover [Wed, 20 Apr 2011 14:54:58 +0000]
move Firebird ODBC driver ->type_info override into driver

13 years ago->type_info fix for buggy Firebird ODBC driver
Rafael Kitover [Wed, 20 Apr 2011 14:45:41 +0000]
->type_info fix for buggy Firebird ODBC driver

13 years agobump MooseX::NonMoose dep up to 0.16
Rafael Kitover [Thu, 14 Apr 2011 03:02:14 +0000]
bump MooseX::NonMoose dep up to 0.16

13 years agoremove Class::Load dependency
Rafael Kitover [Wed, 13 Apr 2011 09:17:18 +0000]
remove Class::Load dependency

13 years agouse sprintf for floating point comparisons in common tests
Rafael Kitover [Wed, 13 Apr 2011 08:38:16 +0000]
use sprintf for floating point comparisons in common tests

13 years agosupport for DBD::Firebird
Rafael Kitover [Sat, 9 Apr 2011 20:12:49 +0000]
support for DBD::Firebird

13 years agoremove special case for 'meta' method in col accessor collision checks
Rafael Kitover [Tue, 29 Mar 2011 00:01:05 +0000]
remove special case for 'meta' method in col accessor collision checks

13 years agoinitialize result_component_map to empty hash if unset 0.07010
Rafael Kitover [Fri, 4 Mar 2011 09:07:56 +0000]
initialize result_component_map to empty hash if unset

13 years agorelease 0.07010
Rafael Kitover [Fri, 4 Mar 2011 08:27:24 +0000]
release 0.07010

13 years agosupport for fully-qualified components in result_component_map and tests
Rafael Kitover [Fri, 4 Mar 2011 08:25:26 +0000]
support for fully-qualified components in result_component_map and tests

13 years agoAdded result_component_map option to Schema::Loader::Base
Mark A. Stratman [Tue, 1 Mar 2011 22:10:10 +0000]
Added result_component_map option to Schema::Loader::Base

13 years agobump up Class::C3::Componentised dep 0.07009
Rafael Kitover [Fri, 25 Feb 2011 11:13:03 +0000]
bump up Class::C3::Componentised dep