Skip to content

Commit d17fe2b

Browse files
committed
Modified creation of posts for spec "when viewing the last page of a collection that has multiple pages"
1 parent dc8acb6 commit d17fe2b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

spec/unit/views/components/paginated_collection_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,9 +174,9 @@
174174
end
175175
end
176176

177-
context "when view last page of collection that has multiple pages" do
177+
context "when viewing the last page of a collection that has multiple pages" do
178178
let(:collection) do
179-
posts = 81.times.inject([]) {|m, _| m << Post.new }
179+
posts = [Post.new] * 81
180180
Kaminari.paginate_array(posts).page(3).per(30)
181181
end
182182

0 commit comments

Comments
 (0)