X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F67pager.t;h=994cf406b77df4372afbb0fa0c3f74616da1d857;hb=e2741c7fd695dca054614f297b01d351a45bbf38;hp=2463369539b028c23477ec0bd4402475a3bcec81;hpb=1c30a2e4a2907330fa59e4ab38a6b56e74136737;p=dbsrgits%2FDBIx-Class.git diff --git a/t/67pager.t b/t/67pager.t index 2463369..994cf40 100644 --- a/t/67pager.t +++ b/t/67pager.t @@ -1,8 +1,10 @@ +BEGIN { do "./t/lib/ANFANG.pm" or die ( $@ || $! ) } + use strict; use warnings; use Test::More; -use lib qw(t/lib); + use DBICTest; my $schema = DBICTest->init_schema(); @@ -69,12 +71,14 @@ $it = $rs->search( { order_by => 'title', rows => 3 } ); -my $page = $it->page(2); -is( $page->count, 2, "standard resultset paged rs count ok" ); +{ + my $page = $it->page(2); -is( $page->next->title, "Generic Manufactured Singles", "second page of standard resultset ok" ); + is( $page->count, 2, "standard resultset paged rs count ok" ); + is( $page->next->title, "Generic Manufactured Singles", "second page of standard resultset ok" ); +} # test software-based limit paging $it = $rs->search(