fixing tests

This commit is contained in:
albert
2011-07-16 19:20:02 -04:00
parent 7d80057e20
commit 58c3d2af13
49 changed files with 896 additions and 488 deletions

View File

@@ -52,7 +52,7 @@ module Danbooru
page = [page.to_i, 1].max
if page > Danbooru.config.max_numbered_pages
raise "You cannot go beyond page #{Danbooru.config.max_numbered_pages}. Please narrow your search terms."
raise PaginationError.new("You cannot go beyond page #{Danbooru.config.max_numbered_pages}. Please narrow your search terms.")
end
limit(records_per_page).offset((page - 1) * records_per_page).tap do |obj|

View File

@@ -0,0 +1,6 @@
module Danbooru
module Paginator
class PaginationError < Exception
end
end
end