Autofix Rubocop RSpec/LeadingSubject (#23670)
This commit is contained in:
parent
4ea1e0fceb
commit
4552685f6b
78 changed files with 256 additions and 338 deletions
|
@ -4,6 +4,8 @@ require 'rails_helper'
|
|||
|
||||
RSpec.describe BlacklistedEmailValidator, type: :validator do
|
||||
describe '#validate' do
|
||||
subject { described_class.new.validate(user); errors }
|
||||
|
||||
let(:user) { double(email: 'info@mail.com', sign_up_ip: '1.2.3.4', errors: errors) }
|
||||
let(:errors) { double(add: nil) }
|
||||
|
||||
|
@ -12,8 +14,6 @@ RSpec.describe BlacklistedEmailValidator, type: :validator do
|
|||
allow_any_instance_of(described_class).to receive(:blocked_email_provider?) { blocked_email }
|
||||
end
|
||||
|
||||
subject { described_class.new.validate(user); errors }
|
||||
|
||||
context 'when e-mail provider is blocked' do
|
||||
let(:blocked_email) { true }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue