More test hackage, some cleanup in ResultSet
[dbsrgits/DBIx-Class.git] / t / run / 07pager.tl
index 9406d71..d864afa 100644 (file)
@@ -4,7 +4,7 @@ my $schema = shift;
 plan tests => 12;
 
 # first page
-my $it = $schema->class("CD")->search(
+my $it = $schema->resultset("CD")->search(
     {},
     { order_by => 'title',
       rows => 3,
@@ -25,7 +25,7 @@ $it->next;
 is( $it->next, undef, "next past end of page ok" );
 
 # second page, testing with array
-my @page2 = $schema->class("CD")->search( 
+my @page2 = $schema->resultset("CD")->search( 
     {},
     { order_by => 'title',
       rows => 3,
@@ -35,7 +35,7 @@ my @page2 = $schema->class("CD")->search(
 is( $page2[0]->title, "Generic Manufactured Singles", "second page first title ok" );
 
 # page a standard resultset
-$it = $schema->class("CD")->search(
+$it = $schema->resultset("CD")->search(
   {},
   { order_by => 'title',
     rows => 3 }
@@ -47,7 +47,7 @@ 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 = $schema->class("CD")->search(
+$it = $schema->resultset("CD")->search(
   {},
   { order_by => 'title',
     rows => 3,