mirror of
https://github.com/mastodon/mastodon.git
synced 2024-08-20 21:08:15 -07:00
18 lines
409 B
Ruby
18 lines
409 B
Ruby
|
require 'rails_helper'
|
||
|
|
||
|
describe Admin::TwoFactorAuthenticationsController do
|
||
|
render_views
|
||
|
|
||
|
let(:user) { Fabricate(:user) }
|
||
|
before do
|
||
|
sign_in Fabricate(:user, admin: true), scope: :user
|
||
|
end
|
||
|
|
||
|
describe 'DELETE #destroy' do
|
||
|
it 'redirects to admin accounts page' do
|
||
|
delete :destroy, params: { user_id: user.id }
|
||
|
expect(response).to redirect_to(admin_accounts_path)
|
||
|
end
|
||
|
end
|
||
|
end
|