[Bast-commits] r6960 - in
branches/DBIx-Class-Schema-Loader/mssql_tweaks:
lib/DBIx/Class/Schema/Loader/DBI t/lib
caelum at dev.catalyst.perl.org
caelum at dev.catalyst.perl.org
Fri Jul 3 04:34:33 GMT 2009
Author: caelum
Date: 2009-07-03 04:34:33 +0000 (Fri, 03 Jul 2009)
New Revision: 6960
Modified:
branches/DBIx-Class-Schema-Loader/mssql_tweaks/lib/DBIx/Class/Schema/Loader/DBI/Sybase.pm
branches/DBIx-Class-Schema-Loader/mssql_tweaks/t/lib/dbixcsl_common_tests.pm
Log:
sybase rels sort of work now, more than half-way through common tests
Modified: branches/DBIx-Class-Schema-Loader/mssql_tweaks/lib/DBIx/Class/Schema/Loader/DBI/Sybase.pm
===================================================================
--- branches/DBIx-Class-Schema-Loader/mssql_tweaks/lib/DBIx/Class/Schema/Loader/DBI/Sybase.pm 2009-07-03 03:33:07 UTC (rev 6959)
+++ branches/DBIx-Class-Schema-Loader/mssql_tweaks/lib/DBIx/Class/Schema/Loader/DBI/Sybase.pm 2009-07-03 04:34:33 UTC (rev 6960)
@@ -94,8 +94,7 @@
while (my $row = $sth->fetchrow_hashref) {
my $fk = $row->{fk_name} ||
-'fk_'.$row->{fktable_qualifier}.'_'.$row->{fktable_owner}.'_'
-.$row->{fktable_name}.'_'.$row->{fkcolumn_name};
+'fk_'.$row->{fktable_name}.'_'.$row->{pktable_name};
push @{$local_cols->{$fk}}, $row->{fkcolumn_name};
push @{$remote_cols->{$fk}}, $row->{pkcolumn_name};
Modified: branches/DBIx-Class-Schema-Loader/mssql_tweaks/t/lib/dbixcsl_common_tests.pm
===================================================================
--- branches/DBIx-Class-Schema-Loader/mssql_tweaks/t/lib/dbixcsl_common_tests.pm 2009-07-03 03:33:07 UTC (rev 6959)
+++ branches/DBIx-Class-Schema-Loader/mssql_tweaks/t/lib/dbixcsl_common_tests.pm 2009-07-03 04:34:33 UTC (rev 6960)
@@ -401,8 +401,11 @@
ok($class6->column_info('loader_test2_id')->{is_foreign_key}, 'Foreign key detected');
ok($class6->column_info('id')->{is_foreign_key}, 'Foreign key detected');
- ok($class6->column_info('id2')->{is_foreign_key}, 'Foreign key detected');
+ my $id2_info = eval { $class6->column_info('id2') } ||
+ $class6->column_info('Id2');
+ ok($id2_info->{is_foreign_key}, 'Foreign key detected');
+
# fk that references a non-pk key (UNIQUE)
my $obj8 = $rsobj8->find(1);
isa_ok( $obj8->loader_test7, $class7);
More information about the Bast-commits
mailing list