You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
469 B

  1. # frozen_string_literal: true
  2. require 'rails_helper'
  3. RSpec.describe Api::V1::Instances::ActivityController, type: :controller do
  4. describe 'GET #show' do
  5. it 'returns 200' do
  6. get :show
  7. expect(response).to have_http_status(200)
  8. end
  9. context '!Setting.activity_api_enabled' do
  10. it 'returns 404' do
  11. Setting.activity_api_enabled = false
  12. get :show
  13. expect(response).to have_http_status(404)
  14. end
  15. end
  16. end
  17. end