From 7506705c96eb23ccd3cd65ae1a9246c362d8f009 Mon Sep 17 00:00:00 2001 From: tooyosi Date: Wed, 4 Sep 2024 17:54:36 +0100 Subject: [PATCH] [issue-4351] renaming test variables --- spec/workers/user_info_changed_mailer_worker_spec.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/spec/workers/user_info_changed_mailer_worker_spec.rb b/spec/workers/user_info_changed_mailer_worker_spec.rb index 39bc6f02e..0cc7f72c8 100644 --- a/spec/workers/user_info_changed_mailer_worker_spec.rb +++ b/spec/workers/user_info_changed_mailer_worker_spec.rb @@ -3,17 +3,17 @@ RSpec.describe UserInfoChangedMailerWorker do let(:project) { create(:project) } let(:user) { create(:user) } - let(:prev_pass) { 'oldpassword@example.com' } + let(:prev_email) { 'oldemaild@example.com' } - context 'email delivery' do + context 'when delivering an email' do it 'delivers the mail' do expect { subject.perform(user.id, 'password') }.to change { ActionMailer::Base.deliveries.count }.by(1) end it 'delivers to the right recipients' do - subject.perform(user.id, 'email', prev_pass) + subject.perform(user.id, 'email', prev_email) mail = ActionMailer::Base.deliveries.last - expect(mail.to).to eq([user.email, prev_pass]) + expect(mail.to).to eq([user.email, prev_email]) end end