use lib qw(t/lib);
use_ok('DBICTest');
-DBICTest::init_schema();
+DBICTest->init_schema();
DBICTest->schema->storage->sql_maker->quote_char("'");
DBICTest->schema->storage->sql_maker->name_sep('.');
BEGIN {
eval "use DBD::SQLite";
plan $ENV{DATA_DUMPER_TEST}
- ? ( tests => 3 )
+ ? ( tests => 2 )
: ( skip_all => 'Set $ENV{DATA_DUMPER_TEST} to run this test' );
}
use_ok('DBICTest');
-use_ok('DBICTest::HelperRels');
-
-my $rs = DBICTest::CD->search(
- { 'artist.name' => 'We Are Goth',
- 'liner_notes.notes' => 'Kill Yourself!' },
- { join => [ qw/artist liner_notes/ ] });
+my $schema = DBICTest->init_schema();
+my $rs = $schema->resultset('CD')->search({
+ 'artist.name' => 'We Are Goth',
+ 'liner_notes.notes' => 'Kill Yourself!',
+}, {
+ join => [ qw/artist liner_notes/ ],
+});
Dumper($rs);
-$rs = DBICTest::CD->search(
- { 'artist.name' => 'We Are Goth',
- 'liner_notes.notes' => 'Kill Yourself!' },
- { join => [ qw/artist liner_notes/ ] });
+$rs = $schema->resultset('CD')->search({
+ 'artist.name' => 'We Are Goth',
+ 'liner_notes.notes' => 'Kill Yourself!',
+}, {
+ join => [ qw/artist liner_notes/ ],
+});
-cmp_ok( $rs + 0, '==', 1, "Single record in after death with dumper");
+cmp_ok( $rs->count(), '==', 1, "Single record in after death with dumper");
1;
use lib qw(t/lib);
use_ok('DBICTest');
-DBICTest::init_schema();
+DBICTest->init_schema();
my $cbworks = 0;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 3;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 4;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 32;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 12;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
eval { require DateTime };
plan skip_all => "Need DateTime for inflation tests" if $@;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
eval { require DateTime };
plan skip_all => "Need DateTime for inflation tests" if $@;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
use Data::Dumper;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
BEGIN {
eval "use DBD::SQLite";
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 2;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
BEGIN {
eval "use DBD::SQLite";
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
use IO::File;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
eval "use DBD::SQLite";
plan skip_all => 'needs DBD::SQLite for testing' if $@;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
# this test will check to see if you can have 2 columns
# in the same class pointing at the same other class
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
eval 'use Data::UUID ; 1'
or plan skip_all => 'Install Data::UUID run this test';
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 34;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 39;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 4;
my $artist = $schema->resultset('Artist')->find(1);
my $cover_band;
{
- no warnings 'redefine';
+ no warnings qw(redefine once);
local *DBICTest::Artist::result_source_instance = \&DBICTest::Schema::Artist::result_source_instance;
$cover_band = $artist->copy;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
my $queries;
$schema->storage->debugcb( sub{ $queries++ } );
use DBICTest;
use Storable;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 1;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
eval 'use Encode ; 1'
or plan skip_all => 'Install Encode run this test';
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
my $queries;
#$schema->storage->debugfh(IO::File->new('t/var/temp.trace', 'w'));
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 321;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
plan tests => 8;
use lib qw(t/lib);
use DBICTest;
-my $schema = DBICTest::init_schema();
+my $schema = DBICTest->init_schema();
eval 'require JSON';
plan skip_all => 'Install JSON to run this test' if ($@);
use lib 't/lib';
use_ok('DBICTest');
-DBICTest::init_schema();
+DBICTest->init_schema();
DBICTest::CD->load_components(qw/CDBICompat::Pager/);