Fix RSpec/ScatteredSetup cop (#24848)
This commit is contained in:
parent
9cbda99941
commit
a610a02d4f
6 changed files with 9 additions and 23 deletions
|
@ -5,16 +5,16 @@ require 'rails_helper'
|
|||
RSpec.describe Admin::Disputes::AppealsController do
|
||||
render_views
|
||||
|
||||
before { sign_in current_user, scope: :user }
|
||||
before do
|
||||
sign_in current_user, scope: :user
|
||||
|
||||
target_account.suspend!
|
||||
end
|
||||
|
||||
let(:target_account) { Fabricate(:account) }
|
||||
let(:strike) { Fabricate(:account_warning, target_account: target_account, action: :suspend) }
|
||||
let(:appeal) { Fabricate(:appeal, strike: strike, account: target_account) }
|
||||
|
||||
before do
|
||||
target_account.suspend!
|
||||
end
|
||||
|
||||
describe 'POST #approve' do
|
||||
let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue