-# $Id: Build.PL 3236 2007-05-05 16:24:35Z claco $\r
-require 'Makefile.PL';\r
+# $Id$
+require 'Makefile.PL';
-\bRCS\b\r
-\bCVS\b\r
-,v$\r
-\B\.svn\b\r
-t/var\r
-^blib/\r
-^pm_to_blib\r
-^MakeMaker-\d\r
-Makefile$\r
-Makefile.old$\r
-Build.PL\r
-Build.bat\r
-\.db\r
-t/TEST$\r
-t/SMOKE$\r
-^blibdirs\.ts\r
+\bRCS\b
+\bCVS\b
+,v$
+\B\.svn\b
+t/var
+^blib/
+^pm_to_blib
+^MakeMaker-\d
+Makefile$
+Makefile.old$
+Build.PL
+Build.bat
+\.db
+t/TEST$
+t/SMOKE$
+^blibdirs\.ts
\.gz
\ No newline at end of file
-# $Id: Makefile.PL 3236 2007-05-05 16:24:35Z claco $\r
-use strict;\r
-use warnings;\r
-use inc::Module::Install 0.65;\r
-\r
-name 'DBIx-Class-UUIDColumns';\r
-license 'perl';\r
-perl_version '5.008001';\r
-all_from 'lib/DBIx/Class/UUIDColumns.pm';\r
-\r
-requires 'DBIx::Class' => '0.07005';\r
-\r
-if (\r
- !eval 'require Data::UUID' &&\r
- !eval 'require ARE::UUID' &&\r
- !eval 'require UUID' &&\r
- !eval 'require Win32::Guidgen' &&\r
- !eval 'require Win32API::GUID' &&\r
- !eval 'require Data::Uniqid'\r
- ) {\r
- requires 'Data::UUID';\r
-};\r
-\r
-build_requires 'DBD::SQLite' => '1.11';\r
-\r
-recommends 'Data::UUID';\r
-recommends 'Data::Uniqid';\r
-recommends 'APR::UUID';\r
-recommends 'UUID';\r
-recommends 'Win32::Guidgen';\r
-recommends 'Win32API::GUID';\r
-\r
-tests "t/*.t t/*/*.t";\r
-clean_files "DBIx-Class-UUIDColumns-* t/var";\r
-\r
-eval {\r
- system 'pod2text lib/DBIx/Class/UUIDColumns.pm > README';\r
-};\r
-\r
-auto_install;\r
-WriteAll;\r
+# $Id$
+use strict;
+use warnings;
+use inc::Module::Install 0.65;
+
+name 'DBIx-Class-UUIDColumns';
+license 'perl';
+perl_version '5.008001';
+all_from 'lib/DBIx/Class/UUIDColumns.pm';
+
+requires 'DBIx::Class' => '0.07005';
+
+if (
+ !eval 'require Data::UUID' &&
+ !eval 'require ARE::UUID' &&
+ !eval 'require UUID' &&
+ !eval 'require Win32::Guidgen' &&
+ !eval 'require Win32API::GUID' &&
+ !eval 'require Data::Uniqid'
+ ) {
+ requires 'Data::UUID';
+};
+
+build_requires 'DBD::SQLite' => '1.11';
+
+recommends 'Data::UUID';
+recommends 'Data::Uniqid';
+recommends 'APR::UUID';
+recommends 'UUID';
+recommends 'Win32::Guidgen';
+recommends 'Win32API::GUID';
+
+tests "t/*.t t/*/*.t";
+clean_files "DBIx-Class-UUIDColumns-* t/var";
+
+eval {
+ system 'pod2text lib/DBIx/Class/UUIDColumns.pm > README';
+};
+
+auto_install;
+WriteAll;
-NAME\r
- DBIx::Class::UUIDColumns - Implicit uuid columns\r
-\r
-SYNOPSIS\r
- In your DBIx::Class table class:\r
-\r
- __PACKAGE__->load_components(qw/UUIDColumns ... Core/);\r
- __PACKAGE__->uuid_columns('artist_id');\r
-\r
- Note: The component needs to be loaded *before* Core.\r
-\r
-DESCRIPTION\r
- This DBIx::Class component resembles the behaviour of Class::DBI::UUID,\r
- to make some columns implicitly created as uuid.\r
-\r
- When loaded, "UUIDColumns" will search for a suitable uuid generation\r
- module from the following list of supported modules:\r
-\r
- Data::UUID\r
- APR::UUID*\r
- UUID\r
- Win32::Guidgen\r
- Win32API::GUID\r
-\r
- If no supporting module can be found, an exception will be thrown.\r
-\r
- *APR::UUID will not be loaded under OpenBSD due to an as yet\r
- unidentified XS issue.\r
-\r
- If you would like to use a specific module, you can set "uuid_class":\r
-\r
- __PACKAGE__->uuid_class('::Data::UUID');\r
- __PACKAGE__->uuid_class('MyUUIDGenerator');\r
-\r
-METHODS\r
- get_uuid\r
- Returns a uuid string from the current uuid_maker.\r
-\r
- insert\r
- Inserts a new uuid string into each column in "uuid_columns".\r
-\r
- uuid_columns\r
- Takes a list of columns to be filled with uuids during insert.\r
-\r
- __PACKAGE__->uuid_columns('artist_id');\r
-\r
- uuid_class\r
- Takes the name of a UUIDMaker subclass to be used for uuid value\r
- generation. This can be a fully qualified class name, or a shortcut name\r
- starting with :: that matches one of the available\r
- DBIx::Class::UUIDColumns::UUIDMaker subclasses:\r
-\r
- __PACKAGE__->uuid_class('CustomUUIDGenerator');\r
- # loads CustomeUUIDGenerator\r
-\r
- __PACKAGE__->uuid_class('::Data::UUID');\r
- # loads DBIx::Class::UUIDMaker::Data::UUID;\r
-\r
- Note that "uuid_class" checks to see that the specified class isa\r
- DBIx::Class::UUIDColumns::UUIDMaker subclass and throws and exception if\r
- it isn't.\r
-\r
- uuid_maker\r
- Returns the current UUIDMaker instance for the given module.\r
-\r
- my $uuid = __PACKAGE__->uuid_maker->as_string;\r
-\r
-SEE ALSO\r
- DBIx::Class::UUIDColumns::UUIDMaker\r
-\r
-AUTHOR\r
- Chia-liang Kao <clkao@clkao.org>\r
-\r
-CONTRIBUTERS\r
- Chris Laco <claco@chrislaco.com>\r
-\r
-LICENSE\r
- You may distribute this code under the same terms as Perl itself.\r
-\r
+NAME
+ DBIx::Class::UUIDColumns - Implicit uuid columns
+
+SYNOPSIS
+ In your DBIx::Class table class:
+
+ __PACKAGE__->load_components(qw/UUIDColumns ... Core/);
+ __PACKAGE__->uuid_columns('artist_id');
+
+ Note: The component needs to be loaded *before* Core.
+
+DESCRIPTION
+ This DBIx::Class component resembles the behaviour of Class::DBI::UUID,
+ to make some columns implicitly created as uuid.
+
+ When loaded, "UUIDColumns" will search for a suitable uuid generation
+ module from the following list of supported modules:
+
+ Data::UUID
+ APR::UUID*
+ UUID
+ Win32::Guidgen
+ Win32API::GUID
+
+ If no supporting module can be found, an exception will be thrown.
+
+ *APR::UUID will not be loaded under OpenBSD due to an as yet
+ unidentified XS issue.
+
+ If you would like to use a specific module, you can set "uuid_class":
+
+ __PACKAGE__->uuid_class('::Data::UUID');
+ __PACKAGE__->uuid_class('MyUUIDGenerator');
+
+METHODS
+ get_uuid
+ Returns a uuid string from the current uuid_maker.
+
+ insert
+ Inserts a new uuid string into each column in "uuid_columns".
+
+ uuid_columns
+ Takes a list of columns to be filled with uuids during insert.
+
+ __PACKAGE__->uuid_columns('artist_id');
+
+ uuid_class
+ Takes the name of a UUIDMaker subclass to be used for uuid value
+ generation. This can be a fully qualified class name, or a shortcut name
+ starting with :: that matches one of the available
+ DBIx::Class::UUIDColumns::UUIDMaker subclasses:
+
+ __PACKAGE__->uuid_class('CustomUUIDGenerator');
+ # loads CustomeUUIDGenerator
+
+ __PACKAGE__->uuid_class('::Data::UUID');
+ # loads DBIx::Class::UUIDMaker::Data::UUID;
+
+ Note that "uuid_class" checks to see that the specified class isa
+ DBIx::Class::UUIDColumns::UUIDMaker subclass and throws and exception if
+ it isn't.
+
+ uuid_maker
+ Returns the current UUIDMaker instance for the given module.
+
+ my $uuid = __PACKAGE__->uuid_maker->as_string;
+
+SEE ALSO
+ DBIx::Class::UUIDColumns::UUIDMaker
+
+AUTHOR
+ Chia-liang Kao <clkao@clkao.org>
+
+CONTRIBUTERS
+ Chris Laco <claco@chrislaco.com>
+
+LICENSE
+ You may distribute this code under the same terms as Perl itself.
+
-#!perl -wT\r
-# $Id: basic.t 3235 2007-05-05 16:23:08Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test tests => 2;\r
-\r
- use_ok('DBIx::Class::UUIDColumns');\r
- use_ok('DBIx::Class::UUIDColumns::UUIDMaker');\r
-};\r
+#!perl -wT
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test tests => 2;
+
+ use_ok('DBIx::Class::UUIDColumns');
+ use_ok('DBIx::Class::UUIDColumns::UUIDMaker');
+};
-# $Id: Test.pm 3236 2007-05-05 16:24:35Z claco $\r
-package DBIC::Test;\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- # little trick by Ovid to pretend to subclass+exporter Test::More\r
- use base qw/Test::Builder::Module Class::Accessor::Grouped/;\r
- use Test::More;\r
- use File::Spec::Functions qw/catfile catdir/;\r
-\r
- @DBIC::Test::EXPORT = @Test::More::EXPORT;\r
-\r
- __PACKAGE__->mk_group_accessors('inherited', qw/db_dir db_file/);\r
-};\r
-\r
-__PACKAGE__->db_dir(catdir('t', 'var'));\r
-__PACKAGE__->db_file('test.db');\r
-\r
-## cribbed and modified from DBICTest in DBIx::Class tests\r
-sub init_schema {\r
- my ($self, %args) = @_;\r
- my $db_dir = $args{'db_dir'} || $self->db_dir;\r
- my $db_file = $args{'db_file'} || $self->db_file;\r
- my $namespace = $args{'namespace'} || 'DBIC::TestSchema';\r
- my $db = catfile($db_dir, $db_file);\r
-\r
- eval 'use DBD::SQLite';\r
- if ($@) {\r
- BAIL_OUT('DBD::SQLite not installed');\r
-\r
- return;\r
- };\r
-\r
- eval 'use DBIC::Test::Schema';\r
- if ($@) {\r
- BAIL_OUT("Could not load DBIC::Test::Schema: $@");\r
-\r
- return;\r
- };\r
-\r
- unlink($db) if -e $db;\r
- unlink($db . '-journal') if -e $db . '-journal';\r
- mkdir($db_dir) unless -d $db_dir;\r
-\r
- my $dsn = 'dbi:SQLite:' . $db;\r
- my $schema = DBIC::Test::Schema->compose_namespace($namespace)->connect($dsn);\r
- $schema->storage->on_connect_do([\r
- 'PRAGMA synchronous = OFF',\r
- 'PRAGMA temp_store = MEMORY'\r
- ]);\r
-\r
- __PACKAGE__->deploy_schema($schema, %args);\r
- __PACKAGE__->populate_schema($schema, %args) unless $args{'no_populate'};\r
-\r
- return $schema;\r
-};\r
-\r
-sub deploy_schema {\r
- my ($self, $schema, %options) = @_;\r
- my $eval = $options{'eval_deploy'};\r
-\r
- eval 'use SQL::Translator';\r
- if (!$@ && !$options{'no_deploy'}) {\r
- eval {\r
- $schema->deploy();\r
- };\r
- if ($@ && !$eval) {\r
- die $@;\r
- };\r
- } else {\r
- open IN, catfile('t', 'sql', 'test.sqlite.sql');\r
- my $sql;\r
- { local $/ = undef; $sql = <IN>; }\r
- close IN;\r
- eval {\r
- ($schema->storage->dbh->do($_) || print "Error on SQL: $_\n") for split(/;\n/, $sql);\r
- };\r
- if ($@ && !$eval) {\r
- die $@;\r
- };\r
- };\r
-};\r
-\r
-sub clear_schema {\r
- my ($self, $schema, %options) = @_;\r
-\r
- foreach my $source ($schema->sources) {\r
- $schema->resultset($source)->delete_all;\r
- };\r
-};\r
-\r
-sub populate_schema {\r
- my ($self, $schema, %options) = @_;\r
- \r
- if ($options{'clear'}) {\r
- $self->clear_schema($schema, %options);\r
- };\r
-};\r
-\r
-sub is_uuid {\r
- my $value = defined $_[0] ? shift : '';\r
-\r
- return ($value =~ m/ ^[0-9a-f]{8}-\r
- [0-9a-f]{4}-\r
- [0-9a-f]{4}-\r
- [0-9a-f]{4}-\r
- [0-9a-f]{12}$\r
- /ix);\r
-};\r
-\r
-1;\r
+# $Id$
+package DBIC::Test;
+use strict;
+use warnings;
+
+BEGIN {
+ # little trick by Ovid to pretend to subclass+exporter Test::More
+ use base qw/Test::Builder::Module Class::Accessor::Grouped/;
+ use Test::More;
+ use File::Spec::Functions qw/catfile catdir/;
+
+ @DBIC::Test::EXPORT = @Test::More::EXPORT;
+
+ __PACKAGE__->mk_group_accessors('inherited', qw/db_dir db_file/);
+};
+
+__PACKAGE__->db_dir(catdir('t', 'var'));
+__PACKAGE__->db_file('test.db');
+
+## cribbed and modified from DBICTest in DBIx::Class tests
+sub init_schema {
+ my ($self, %args) = @_;
+ my $db_dir = $args{'db_dir'} || $self->db_dir;
+ my $db_file = $args{'db_file'} || $self->db_file;
+ my $namespace = $args{'namespace'} || 'DBIC::TestSchema';
+ my $db = catfile($db_dir, $db_file);
+
+ eval 'use DBD::SQLite';
+ if ($@) {
+ BAIL_OUT('DBD::SQLite not installed');
+
+ return;
+ };
+
+ eval 'use DBIC::Test::Schema';
+ if ($@) {
+ BAIL_OUT("Could not load DBIC::Test::Schema: $@");
+
+ return;
+ };
+
+ unlink($db) if -e $db;
+ unlink($db . '-journal') if -e $db . '-journal';
+ mkdir($db_dir) unless -d $db_dir;
+
+ my $dsn = 'dbi:SQLite:' . $db;
+ my $schema = DBIC::Test::Schema->compose_namespace($namespace)->connect($dsn);
+ $schema->storage->on_connect_do([
+ 'PRAGMA synchronous = OFF',
+ 'PRAGMA temp_store = MEMORY'
+ ]);
+
+ __PACKAGE__->deploy_schema($schema, %args);
+ __PACKAGE__->populate_schema($schema, %args) unless $args{'no_populate'};
+
+ return $schema;
+};
+
+sub deploy_schema {
+ my ($self, $schema, %options) = @_;
+ my $eval = $options{'eval_deploy'};
+
+ eval 'use SQL::Translator';
+ if (!$@ && !$options{'no_deploy'}) {
+ eval {
+ $schema->deploy();
+ };
+ if ($@ && !$eval) {
+ die $@;
+ };
+ } else {
+ open IN, catfile('t', 'sql', 'test.sqlite.sql');
+ my $sql;
+ { local $/ = undef; $sql = <IN>; }
+ close IN;
+ eval {
+ ($schema->storage->dbh->do($_) || print "Error on SQL: $_\n") for split(/;\n/, $sql);
+ };
+ if ($@ && !$eval) {
+ die $@;
+ };
+ };
+};
+
+sub clear_schema {
+ my ($self, $schema, %options) = @_;
+
+ foreach my $source ($schema->sources) {
+ $schema->resultset($source)->delete_all;
+ };
+};
+
+sub populate_schema {
+ my ($self, $schema, %options) = @_;
+
+ if ($options{'clear'}) {
+ $self->clear_schema($schema, %options);
+ };
+};
+
+sub is_uuid {
+ my $value = defined $_[0] ? shift : '';
+
+ return ($value =~ m/ ^[0-9a-f]{8}-
+ [0-9a-f]{4}-
+ [0-9a-f]{4}-
+ [0-9a-f]{4}-
+ [0-9a-f]{12}$
+ /ix);
+};
+
+1;
-# $Id: Schema.pm 3236 2007-05-05 16:24:35Z claco $\r
-package DBIC::Test::Schema;\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use base qw/DBIx::Class::Schema/;\r
-};\r
-__PACKAGE__->load_classes;\r
-\r
-sub dsn {\r
- return shift->storage->connect_info->[0];\r
-};\r
-\r
-1;\r
+# $Id$
+package DBIC::Test::Schema;
+use strict;
+use warnings;
+
+BEGIN {
+ use base qw/DBIx::Class::Schema/;
+};
+__PACKAGE__->load_classes;
+
+sub dsn {
+ return shift->storage->connect_info->[0];
+};
+
+1;
-# $Id: Test.pm 3236 2007-05-05 16:24:35Z claco $\r
-package DBIC::Test::Schema::Test;\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use base qw/DBIx::Class::Core/;\r
-};\r
-\r
-__PACKAGE__->load_components(qw/UUIDColumns Core/);\r
-__PACKAGE__->table('test');\r
-__PACKAGE__->add_columns(\r
- 'id' => {\r
- data_type => 'varchar',\r
- size => 36,\r
- },\r
-);\r
-__PACKAGE__->set_primary_key('id');\r
-__PACKAGE__->uuid_columns('id');\r
-\r
-1;\r
+# $Id$
+package DBIC::Test::Schema::Test;
+use strict;
+use warnings;
+
+BEGIN {
+ use base qw/DBIx::Class::Core/;
+};
+
+__PACKAGE__->load_components(qw/UUIDColumns Core/);
+__PACKAGE__->table('test');
+__PACKAGE__->add_columns(
+ 'id' => {
+ data_type => 'varchar',
+ size => 36,
+ },
+);
+__PACKAGE__->set_primary_key('id');
+__PACKAGE__->uuid_columns('id');
+
+1;
-#!perl -wT\r
-# $Id: manifest.t 3236 2007-05-05 16:24:35Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test;\r
-\r
- plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};\r
-\r
- eval 'use Test::CheckManifest 0.09';\r
- if($@) {\r
- plan skip_all => 'Test::CheckManifest 0.09 not installed';\r
- };\r
-};\r
-\r
-ok_manifest({\r
- exclude => ['/t/var', '/cover_db'],\r
- filter => [qr/\.svn/, qr/cover/, qr/Build(.(PL|bat))?/, qr/_build/],\r
- bool => 'or'\r
-});\r
+#!perl -wT
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test;
+
+ plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};
+
+ eval 'use Test::CheckManifest 0.09';
+ if($@) {
+ plan skip_all => 'Test::CheckManifest 0.09 not installed';
+ };
+};
+
+ok_manifest({
+ exclude => ['/t/var', '/cover_db'],
+ filter => [qr/\.svn/, qr/cover/, qr/Build(.(PL|bat))?/, qr/_build/],
+ bool => 'or'
+});
-#!perl -wT\r
-# $Id: pod_coverage.t 3236 2007-05-05 16:24:35Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test;\r
-\r
- plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};\r
-\r
- eval 'use Test::Pod::Coverage 1.04';\r
- plan skip_all => 'Test::Pod::Coverage 1.04' if $@;\r
-\r
- eval 'use Pod::Coverage 0.14';\r
- plan skip_all => 'Pod::Coverage 0.14 not installed' if $@;\r
-};\r
-\r
-my $trustme = {\r
- trustme => [qr/^(g|s)et_component_class$/]\r
-};\r
-\r
-all_pod_coverage_ok($trustme);\r
+#!perl -wT
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test;
+
+ plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};
+
+ eval 'use Test::Pod::Coverage 1.04';
+ plan skip_all => 'Test::Pod::Coverage 1.04' if $@;
+
+ eval 'use Pod::Coverage 0.14';
+ plan skip_all => 'Pod::Coverage 0.14 not installed' if $@;
+};
+
+my $trustme = {
+ trustme => [qr/^(g|s)et_component_class$/]
+};
+
+all_pod_coverage_ok($trustme);
-#!perl -w\r
-# $Id: pod_spelling.t 3235 2007-05-05 16:23:08Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test;\r
-\r
- plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};\r
-\r
- eval 'use Test::Spelling 0.11';\r
- plan skip_all => 'Test::Spelling 0.11 not installed' if $@;\r
-};\r
-\r
-set_spell_cmd('aspell list');\r
-\r
-add_stopwords(<DATA>);\r
-\r
-all_pod_files_spelling_ok();\r
-\r
-__DATA__\r
-uuid\r
-uuids\r
-Chia\r
-liang\r
-Kao\r
-Laco\r
-OpenBSD\r
-UUIDMaker\r
-behaviour\r
-isa\r
+#!perl -w
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test;
+
+ plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};
+
+ eval 'use Test::Spelling 0.11';
+ plan skip_all => 'Test::Spelling 0.11 not installed' if $@;
+};
+
+set_spell_cmd('aspell list');
+
+add_stopwords(<DATA>);
+
+all_pod_files_spelling_ok();
+
+__DATA__
+uuid
+uuids
+Chia
+liang
+Kao
+Laco
+OpenBSD
+UUIDMaker
+behaviour
+isa
-#!perl -wT\r
-# $Id: pod_syntax.t 3236 2007-05-05 16:24:35Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test;\r
-\r
- plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};\r
-\r
- eval 'use Test::Pod 1.00';\r
- plan skip_all => 'Test::Pod 1.00 not installed' if $@;\r
-};\r
-\r
-all_pod_files_ok();\r
+#!perl -wT
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test;
+
+ plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};
+
+ eval 'use Test::Pod 1.00';
+ plan skip_all => 'Test::Pod 1.00 not installed' if $@;
+};
+
+all_pod_files_ok();
-CREATE TABLE test (\r
- id VARVHAR(36) PRIMARY KEY NOT NULL\r
-);\r
+CREATE TABLE test (
+ id VARVHAR(36) PRIMARY KEY NOT NULL
+);
-#!perl -wT\r
-# $Id: strict.t 3236 2007-05-05 16:24:35Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test;\r
- use File::Find;\r
- use File::Basename;\r
-\r
- plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};\r
-\r
- eval 'use Test::Strict';\r
- plan skip_all => 'Test::Strict not installed' if $@;\r
- plan skip_all => 'Need untaint in newer File::Find' if $] <= 5.006;\r
-};\r
-\r
-## I hope this can go away if Test::Strict or File::Find::Rule\r
-## finally run under -T. Until then, I'm on my own here. ;-)\r
-my @files;\r
-my %trusted = (\r
-\r
-);\r
-\r
-find({ wanted => \&wanted,\r
- untaint => 1,\r
- untaint_pattern => qr|^([-+@\w./]+)$|,\r
- untaint_skip => 1,\r
- no_chdir => 1\r
-}, qw(lib t));\r
-\r
-sub wanted {\r
- my $name = $File::Find::name;\r
- my $file = fileparse($name);\r
-\r
- return if $name =~ /TestApp/;\r
-\r
- if ($name =~ /\.(pm|pl|t)$/i && !exists($trusted{$file})) {\r
- push @files, $name;\r
- };\r
-};\r
-\r
-if (scalar @files) {\r
- plan tests => scalar @files;\r
-} else {\r
- plan tests => 1;\r
- fail 'No perl files found for Test::Strict checks!';\r
-};\r
-\r
-foreach (@files) {\r
- strict_ok($_);\r
-};\r
+#!perl -wT
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test;
+ use File::Find;
+ use File::Basename;
+
+ plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};
+
+ eval 'use Test::Strict';
+ plan skip_all => 'Test::Strict not installed' if $@;
+ plan skip_all => 'Need untaint in newer File::Find' if $] <= 5.006;
+};
+
+## I hope this can go away if Test::Strict or File::Find::Rule
+## finally run under -T. Until then, I'm on my own here. ;-)
+my @files;
+my %trusted = (
+
+);
+
+find({ wanted => \&wanted,
+ untaint => 1,
+ untaint_pattern => qr|^([-+@\w./]+)$|,
+ untaint_skip => 1,
+ no_chdir => 1
+}, qw(lib t));
+
+sub wanted {
+ my $name = $File::Find::name;
+ my $file = fileparse($name);
+
+ return if $name =~ /TestApp/;
+
+ if ($name =~ /\.(pm|pl|t)$/i && !exists($trusted{$file})) {
+ push @files, $name;
+ };
+};
+
+if (scalar @files) {
+ plan tests => scalar @files;
+} else {
+ plan tests => 1;
+ fail 'No perl files found for Test::Strict checks!';
+};
+
+foreach (@files) {
+ strict_ok($_);
+};
-#!perl -wT\r
-# $Id: style_no_tabs.t 3236 2007-05-05 16:24:35Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test;\r
-\r
- plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};\r
-\r
- eval 'use Test::NoTabs 0.03';\r
- plan skip_all => 'Test::NoTabs 0.03 not installed' if $@;\r
-};\r
-\r
-all_perl_files_ok('lib');\r
+#!perl -wT
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test;
+
+ plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};
+
+ eval 'use Test::NoTabs 0.03';
+ plan skip_all => 'Test::NoTabs 0.03 not installed' if $@;
+};
+
+all_perl_files_ok('lib');
#!perl -wT
-# $Id: basic.t 3235 2007-05-05 16:23:08Z claco $
+# $Id$
use strict;
use warnings;
-#!perl -wT\r
-# $Id: warnings.t 3236 2007-05-05 16:24:35Z claco $\r
-use strict;\r
-use warnings;\r
-\r
-BEGIN {\r
- use lib 't/lib';\r
- use DBIC::Test;\r
- use File::Find;\r
- use File::Basename;\r
-\r
- plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};\r
-\r
- eval 'use Test::Strict 0.05';\r
- plan skip_all => 'Test::Strict 0.05 not installed' if $@;\r
- plan skip_all => 'Need untaint in newer File::Find' if $] <= 5.006;\r
-};\r
-\r
-## I hope this can go away if Test::Strict or File::Find::Rule\r
-## finally run under -T. Until then, I'm on my own here. ;-)\r
-my @files;\r
-my %trusted = (\r
-\r
-);\r
-\r
-find({ wanted => \&wanted,\r
- untaint => 1,\r
- untaint_pattern => qr|^([-+@\w./]+)$|,\r
- untaint_skip => 1,\r
- no_chdir => 1\r
-}, qw(lib t));\r
-\r
-sub wanted {\r
- my $name = $File::Find::name;\r
- my $file = fileparse($name);\r
-\r
- return if $name =~ /TestApp/;\r
-\r
- if ($name =~ /\.(pm|pl|t)$/i && !exists($trusted{$file})) {\r
- push @files, $name;\r
- };\r
-};\r
-\r
-if (scalar @files) {\r
- plan tests => scalar @files;\r
-} else {\r
- plan tests => 1;\r
- fail 'No perl files found for Test::Strict checks!';\r
-};\r
-\r
-foreach (@files) {\r
- warnings_ok($_);\r
-};\r
+#!perl -wT
+# $Id$
+use strict;
+use warnings;
+
+BEGIN {
+ use lib 't/lib';
+ use DBIC::Test;
+ use File::Find;
+ use File::Basename;
+
+ plan skip_all => 'set TEST_AUTHOR to enable this test' unless $ENV{TEST_AUTHOR};
+
+ eval 'use Test::Strict 0.05';
+ plan skip_all => 'Test::Strict 0.05 not installed' if $@;
+ plan skip_all => 'Need untaint in newer File::Find' if $] <= 5.006;
+};
+
+## I hope this can go away if Test::Strict or File::Find::Rule
+## finally run under -T. Until then, I'm on my own here. ;-)
+my @files;
+my %trusted = (
+
+);
+
+find({ wanted => \&wanted,
+ untaint => 1,
+ untaint_pattern => qr|^([-+@\w./]+)$|,
+ untaint_skip => 1,
+ no_chdir => 1
+}, qw(lib t));
+
+sub wanted {
+ my $name = $File::Find::name;
+ my $file = fileparse($name);
+
+ return if $name =~ /TestApp/;
+
+ if ($name =~ /\.(pm|pl|t)$/i && !exists($trusted{$file})) {
+ push @files, $name;
+ };
+};
+
+if (scalar @files) {
+ plan tests => scalar @files;
+} else {
+ plan tests => 1;
+ fail 'No perl files found for Test::Strict checks!';
+};
+
+foreach (@files) {
+ warnings_ok($_);
+};