Skip to content

Commit

Permalink
Update test description [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
yuki24 committed Dec 20, 2017
1 parent cd85dd6 commit 9976b6e
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def self.shutdown
assert_no_queries { @scope.each }
end

test 'when on the first page' do
test '#last_page? returns false when total count == 26 and page size == 25' do
@users = User.page(1).without_count

assert_equal 25, @users.size
Expand All @@ -42,7 +42,7 @@ def self.shutdown
assert_not @users.out_of_range?
end

test 'when on the first page showing 26 elements' do
test '#last_page? returns true when total count == page size' do
@users = User.page(1).per(26).without_count

assert_equal 26, @users.size
Expand All @@ -51,7 +51,7 @@ def self.shutdown
assert_not @users.out_of_range?
end

test 'when on the last page' do
test '#last_page? returns true when total count == 26, page size == 25, and page == 2' do
@users = User.page(2).without_count

assert_equal 1, @users.size
Expand All @@ -60,7 +60,7 @@ def self.shutdown
assert_not @users.out_of_range?
end

test 'when out of range' do
test '#out_of_range? returns true when total count == 26, page size == 25, and page == 3' do
@users = User.page(3).without_count

assert_equal 0, @users.size
Expand Down

0 comments on commit 9976b6e

Please sign in to comment.