Bump version to accomodate pre-beta testers
[dbsrgits/DBIx-Class.git] / t / 26dumper.t
index 6904fdc..c964655 100644 (file)
@@ -1,36 +1,32 @@
+BEGIN { do "./t/lib/ANFANG.pm" or die ( $@ || $! ) }
+
 use strict;
+use warnings;
 use Test::More;
-use IO::File;
 
 use Data::Dumper;
 $Data::Dumper::Sortkeys = 1;
 
-use lib qw(t/lib);
-
-BEGIN {
-    eval "use DBD::SQLite";
-    plan $ENV{DATA_DUMPER_TEST}
-        ? ( tests => 3 )
-        : ( 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;
+done_testing;