Fix unit tests errors due to extended pagination options

pull/1075/head
Till Breuer 11 years ago
parent e0c3946233
commit 702a49ea17
  1. 2
      test/functional/messages_controller_test.rb
  2. 12
      test/integration/api_test/issues_test.rb

@ -61,7 +61,7 @@ class MessagesControllerTest < ActionController::TestCase
message.children << m
end
end
get :show, :board_id => 1, :id => 1, :r => message.children.last(:order => 'id').id
get :show, board_id: 1, id: 1, per_page: 100, r: message.children.last(order: 'id').id
assert_response :success
assert_template 'show'
replies = assigns(:replies)

@ -44,12 +44,12 @@ class ApiTest::IssuesTest < ActionDispatch::IntegrationTest
should "contain metadata" do
get '/api/v1/issues.xml'
assert_tag :tag => 'issues',
:attributes => {
:type => 'array',
:total_count => assigns(:issues).total_entries,
:limit => 100,
:offset => 0
assert_tag tag: 'issues',
attributes: {
type: 'array',
total_count: assigns(:issues).total_entries,
limit: Setting.per_page_options_array.first,
offset: 0
}
end

Loading…
Cancel
Save