0
0
Fork 0

Default to json type for webfinger requests (#1583)

This commit is contained in:
Matt Jankowski 2017-04-12 10:03:37 -04:00 committed by Eugen
parent fd102059aa
commit b352a8e5d4
4 changed files with 36 additions and 8 deletions

View file

@ -14,12 +14,12 @@ RSpec.describe XrdController, type: :controller do
let(:alice) { Fabricate(:account, username: 'alice') }
it 'returns http success when account can be found' do
get :webfinger, params: { resource: alice.to_webfinger_s }
get :webfinger, params: { resource: alice.to_webfinger_s }, format: :json
expect(response).to have_http_status(:success)
end
it 'returns http not found when account cannot be found' do
get :webfinger, params: { resource: 'acct:not@existing.com' }
get :webfinger, params: { resource: 'acct:not@existing.com' }, format: :json
expect(response).to have_http_status(:not_found)
end
end