Actually test if correct field gets set in error response

This commit is contained in:
Daniel Schädler 2019-06-13 13:28:34 +02:00
parent c8f69ccb16
commit 63db00b9ff
1 changed files with 1 additions and 1 deletions

View File

@ -201,7 +201,7 @@ RSpec.describe TournamentsController, type: :controller do
expect(response).to have_http_status(:unprocessable_entity) expect(response).to have_http_status(:unprocessable_entity)
end end
it 'returns the correct error message' do it 'returns the correct error message' do
expect(deserialize_response(response).values.first.first) expect(deserialize_response(response)[:playoff_teams_amount].first)
.to eq('playoff_teams_amount needs to be a positive power of two') .to eq('playoff_teams_amount needs to be a positive power of two')
end end
end end