From: Peter Rabbitson Date: Sun, 29 Mar 2009 08:31:47 +0000 (+0000) Subject: detabify X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c24e75ad97524ff3d75880c6d604cbad3dbd57c2;p=dbsrgits%2FDBIx-Class-Historic.git detabify --- diff --git a/t/39load_namespaces_rt41083.t b/t/39load_namespaces_rt41083.t index e0620fe..3f037a8 100644 --- a/t/39load_namespaces_rt41083.t +++ b/t/39load_namespaces_rt41083.t @@ -9,26 +9,26 @@ use lib 't/lib'; plan tests => 6; sub _chk_warning { - defined $_[0]? - $_[0] !~ qr/We found ResultSet class '([^']+)' for '([^']+)', but it seems that you had already set '([^']+)' to use '([^']+)' instead/ : - 1 + defined $_[0]? + $_[0] !~ qr/We found ResultSet class '([^']+)' for '([^']+)', but it seems that you had already set '([^']+)' to use '([^']+)' instead/ : + 1 } sub _chk_extra_sources_warning { - my $p = qr/already has a source, use register_extra_source for additional sources/; - defined $_[0]? $_[0] !~ /$p/ : 1; + my $p = qr/already has a source, use register_extra_source for additional sources/; + defined $_[0]? $_[0] !~ /$p/ : 1; } my $warnings; eval { - local $SIG{__WARN__} = sub { $warnings .= shift }; - package DBICNSTest::RtBug41083; - use base 'DBIx::Class::Schema'; - __PACKAGE__->load_namespaces( - result_namespace => 'Schema_A', - resultset_namespace => 'ResultSet_A', - default_resultset_class => 'ResultSet' - ); + local $SIG{__WARN__} = sub { $warnings .= shift }; + package DBICNSTest::RtBug41083; + use base 'DBIx::Class::Schema'; + __PACKAGE__->load_namespaces( + result_namespace => 'Schema_A', + resultset_namespace => 'ResultSet_A', + default_resultset_class => 'ResultSet' + ); }; ok(!$@) or diag $@; ok(_chk_warning($warnings), 'expected no resultset complaint'); @@ -36,14 +36,14 @@ ok(_chk_extra_sources_warning($warnings), 'expected no extra sources complaint') undef $warnings; eval { - local $SIG{__WARN__} = sub { $warnings .= shift }; - package DBICNSTest::RtBug41083; - use base 'DBIx::Class::Schema'; - __PACKAGE__->load_namespaces( - result_namespace => 'Schema', - resultset_namespace => 'ResultSet', - default_resultset_class => 'ResultSet' - ); + local $SIG{__WARN__} = sub { $warnings .= shift }; + package DBICNSTest::RtBug41083; + use base 'DBIx::Class::Schema'; + __PACKAGE__->load_namespaces( + result_namespace => 'Schema', + resultset_namespace => 'ResultSet', + default_resultset_class => 'ResultSet' + ); }; ok(!$@) or diag $@; ok(_chk_warning($warnings), 'expected no resultset complaint') or diag $warnings;