Skip to content

Commit

Permalink
Remove in_person_please_call email
Browse files Browse the repository at this point in the history
This has been renamed to idv_please_call.

[skip changelog]
  • Loading branch information
matthinz committed Dec 18, 2024
1 parent e3f9de4 commit 5b4faea
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 34 deletions.
2 changes: 0 additions & 2 deletions app/mailers/user_mailer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,6 @@ def idv_please_call(**)
end
end

alias_method :in_person_please_call, :idv_please_call

def in_person_completion_survey
with_user_locale(user) do
@header = t('user_mailer.in_person_completion_survey.header')
Expand Down
2 changes: 1 addition & 1 deletion spec/mailers/previews/user_mailer_preview_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
require_relative './user_mailer_preview'

RSpec.describe UserMailerPreview do
it_behaves_like 'a mailer preview', preview_methods_that_can_be_missing: [:in_person_please_call]
it_behaves_like 'a mailer preview'

it 'uses user and email records that cannot be saved' do
expect(User.count).to eq(0)
Expand Down
31 changes: 0 additions & 31 deletions spec/mailers/user_mailer_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1319,37 +1319,6 @@ def expect_email_body_to_have_help_and_contact_links
end
end

describe '#in_person_please_call' do
let(:mail) do
UserMailer.with(user: user, email_address: email_address).in_person_please_call(
enrollment: enrollment,
visited_location_name: visited_location_name,
)
end

it_behaves_like 'a system email'
it_behaves_like 'an email that respects user email locale preference'

it 'renders the idv_please_call template' do
expect_any_instance_of(ActionMailer::Base).to receive(:mail)
.with(hash_including(template_name: 'idv_please_call'))
.and_call_original

mail.deliver_later
end

context 'when the keyword argument visited_location_name is missing' do
let(:mail) do
UserMailer.with(user: user, email_address: email_address).in_person_please_call(
enrollment: enrollment,
)
end
it 'sends the email successfully' do
mail.deliver_later
end
end
end

describe '#in_person_completion_survey' do
let(:mail) do
UserMailer.with(user: user, email_address: email_address).in_person_completion_survey
Expand Down

0 comments on commit 5b4faea

Please sign in to comment.