1
0
Fork 0
mirror of https://github.com/kaminari/kaminari.git synced 2022-11-09 13:44:37 -05:00

Using old ruby hash syntax

This commit is contained in:
Kleber Shimabuku 2014-09-24 11:47:27 -03:00 committed by Yuki Nishijima
parent 1c58998201
commit 72de98db0c

View file

@ -32,13 +32,13 @@ describe 'Kaminari::ActionViewExtension', :if => defined?(Rails) do
specify '#total_pages' do
@users = User.page(1).per(1)
result = helper.paginate @users, total_pages: 3, :params => {:controller => 'users', :action => 'index'}
result = helper.paginate @users, :total_pages => 3, :params => {:controller => 'users', :action => 'index'}
expect(result.scan('<span class="page">').count).to eq(2)
end
specify '#total_pages legacy' do
@users = User.page(1).per(1)
result = helper.paginate @users, num_pages: 3, :params => {:controller => 'users', :action => 'index'}
result = helper.paginate @users, :num_pages => 3, :params => {:controller => 'users', :action => 'index'}
expect(result.scan('<span class="page">').count).to eq(2)
end