oembed_controller_spec.rb 526 B

12345678910111213141516171819
  1. require 'rails_helper'
  2. RSpec.describe Api::OEmbedController, type: :controller do
  3. render_views
  4. let(:alice) { Fabricate(:account, username: 'alice') }
  5. let(:status) { Fabricate(:status, text: 'Hello world', account: alice) }
  6. describe 'GET #show' do
  7. before do
  8. request.host = Rails.configuration.x.local_domain
  9. get :show, params: { url: short_account_status_url(alice, status) }, format: :json
  10. end
  11. it 'returns http success' do
  12. expect(response).to have_http_status(200)
  13. end
  14. end
  15. end