2
0

Fix RSpec/AnyInstance cop (#27810)

This commit is contained in:
Matt Jankowski
2023-11-14 09:52:59 -05:00
committed by GitHub
parent d562fb8459
commit b2c5b20ef2
14 changed files with 70 additions and 60 deletions

View File

@@ -227,7 +227,8 @@ RSpec.describe Admin::AccountsController do
let(:account) { Fabricate(:account, domain: 'example.com') }
before do
allow_any_instance_of(ResolveAccountService).to receive(:call)
service = instance_double(ResolveAccountService, call: nil)
allow(ResolveAccountService).to receive(:new).and_return(service)
end
context 'when user is admin' do