spec/collection_spec.rb in vj-sdk-0.7.1 vs spec/collection_spec.rb in vj-sdk-0.7.2

- old
+ new

@@ -36,6 +36,17 @@ collection = Videojuicer::Resource::Collection.new(@objects[0..9], 155, 17, nil) collection.page_count.should == 1 collection.page_number.should == 1 end + it "provides a correct offset for a page number and limit when the page is 1" do + offset = Videojuicer::Resource::Collection.limit_from_page_number 1, 20 + offset.should == 0 + end + + it "should provide a correct offset" do + offset = Videojuicer::Resource::Collection.limit_from_page_number 2, 20 + offset.should == 20 + end + + end \ No newline at end of file