[Bast-commits] r6721 -
DBIx-Class/0.08/branches/prefetch_limit/t/prefetch
ribasushi at dev.catalyst.perl.org
ribasushi at dev.catalyst.perl.org
Fri Jun 19 14:36:08 GMT 2009
Author: ribasushi
Date: 2009-06-19 14:36:08 +0000 (Fri, 19 Jun 2009)
New Revision: 6721
Modified:
DBIx-Class/0.08/branches/prefetch_limit/t/prefetch/with_limit.t
Log:
throw in an extra limit, sophisticate test a bit
Modified: DBIx-Class/0.08/branches/prefetch_limit/t/prefetch/with_limit.t
===================================================================
--- DBIx-Class/0.08/branches/prefetch_limit/t/prefetch/with_limit.t 2009-06-19 14:33:49 UTC (rev 6720)
+++ DBIx-Class/0.08/branches/prefetch_limit/t/prefetch/with_limit.t 2009-06-19 14:36:08 UTC (rev 6721)
@@ -8,7 +8,7 @@
use lib qw(t/lib);
use DBICTest;
-plan tests => 8;
+plan tests => 9;
my $schema = DBICTest->init_schema();
@@ -85,6 +85,9 @@
);
my $artist = $use_prefetch->search({'cds.title' => $artist_many_cds->cds->first->title })->next;
-
is($artist->cds->count, 1, "count on search limiting prefetched has_many");
+# try with double limit
+my $artist2 = $use_prefetch->search({'cds.title' => { '!=' => $artist_many_cds->cds->first->title } })->slice (0,0)->next;
+is($artist2->cds->count, 2, "count on search limiting prefetched has_many");
+
More information about the Bast-commits
mailing list