X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fprefetch%2Fattrs_untouched.t;h=b2f25c38c4e6a165e09926cd96a009c205284bb2;hb=9ae300a43ff4db9bf5084a009cce726c694f3612;hp=17427702d9e172f8443c73fb732df7fb8a081425;hpb=e9bd1473080b4aaf94e2be97329d74703d41a353;p=dbsrgits%2FDBIx-Class.git diff --git a/t/prefetch/attrs_untouched.t b/t/prefetch/attrs_untouched.t index 1742770..b2f25c3 100644 --- a/t/prefetch/attrs_untouched.t +++ b/t/prefetch/attrs_untouched.t @@ -1,35 +1,16 @@ -use warnings; +use warnings; +use strict; use Test::More; -use Test::Exception; use lib qw(t/lib); use DBICTest; + use Data::Dumper; +$Data::Dumper::Sortkeys = 1; my $schema = DBICTest->init_schema(); -my $orig_debug = $schema->storage->debug; - -use IO::File; - -BEGIN { - eval "use DBD::SQLite"; - plan $@ - ? ( skip_all => 'needs DBD::SQLite for testing' ) - : ( tests => 3 ); -} - -# figure out if we've got a version of sqlite that is older than 3.2.6, in -# which case COUNT(DISTINCT()) doesn't work -my $is_broken_sqlite = 0; -my ($sqlite_major_ver,$sqlite_minor_ver,$sqlite_patch_ver) = - split /\./, $schema->storage->dbh->get_info(18); -if( $schema->storage->dbh->get_info(17) eq 'SQLite' && - ( ($sqlite_major_ver < 3) || - ($sqlite_major_ver == 3 && $sqlite_minor_ver < 2) || - ($sqlite_major_ver == 3 && $sqlite_minor_ver == 2 && $sqlite_patch_ver < 6) ) ) { - $is_broken_sqlite = 1; -} +plan tests => 3; # bug in 0.07000 caused attr (join/prefetch) to be modifed by search # so we check the search & attr arrays are not modified