diff --git a/spec/controllers/matches_controller_spec.rb b/spec/controllers/matches_controller_spec.rb index d36e9ba..ec9c725 100644 --- a/spec/controllers/matches_controller_spec.rb +++ b/spec/controllers/matches_controller_spec.rb @@ -49,7 +49,7 @@ RSpec.describe MatchesController, type: :controller do it 'should return success' do get :show, params: { id: @match.to_param } expect(response).to be_successful - expect(response.content_type).to eq('application/json') + expect(response.media_type).to eq('application/json') end it 'should return the correct state' do diff --git a/spec/controllers/tournaments_controller_spec.rb b/spec/controllers/tournaments_controller_spec.rb index fade45b..2e9307c 100644 --- a/spec/controllers/tournaments_controller_spec.rb +++ b/spec/controllers/tournaments_controller_spec.rb @@ -248,7 +248,7 @@ RSpec.describe TournamentsController, type: :controller do it 'renders a JSON response with the new tournament' do post :create, params: create_playoff_tournament_data expect(response).to have_http_status(:created) - expect(response.content_type).to eq('application/json') + expect(response.media_type).to eq('application/json') expect(response.location).to eq(tournament_url(Tournament.last)) end end @@ -329,7 +329,7 @@ RSpec.describe TournamentsController, type: :controller do it 'renders a JSON response with the tournament' do put :update, params: { id: @tournament.to_param }.merge(valid_update) expect(response).to have_http_status(:ok) - expect(response.content_type).to eq('application/json') + expect(response.media_type).to eq('application/json') end context 'any variable relevant for group stage to playoff transition changed' do