diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-05-19 10:33:21 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-05-19 10:33:21 +0300 |
commit | 36a59d088eca61b834191dacea009677a96c052f (patch) | |
tree | e4f33972dab5d8ef79e3944a9f403035fceea43f /spec/mailers/emails/in_product_marketing_spec.rb | |
parent | a1761f15ec2cae7c7f7bbda39a75494add0dfd6f (diff) |
Add latest changes from gitlab-org/gitlab@15-0-stable-eev15.0.0-rc42
Diffstat (limited to 'spec/mailers/emails/in_product_marketing_spec.rb')
-rw-r--r-- | spec/mailers/emails/in_product_marketing_spec.rb | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/spec/mailers/emails/in_product_marketing_spec.rb b/spec/mailers/emails/in_product_marketing_spec.rb index e62719f4283..7f3896a3d51 100644 --- a/spec/mailers/emails/in_product_marketing_spec.rb +++ b/spec/mailers/emails/in_product_marketing_spec.rb @@ -103,4 +103,28 @@ RSpec.describe Emails::InProductMarketing do end end end + + describe '#build_ios_app_guide_email' do + subject { Notify.build_ios_app_guide_email(user.notification_email_or_default) } + + it 'sends to the right user' do + expect(subject).to deliver_to(user.notification_email_or_default) + end + + it 'has the correct subject and content' do + message = Gitlab::Email::Message::BuildIosAppGuide.new + cta_url = 'https://about.gitlab.com/blog/2019/03/06/ios-publishing-with-gitlab-and-fastlane/' + cta2_url = 'https://www.youtube.com/watch?v=325FyJt7ZG8' + + aggregate_failures do + is_expected.to have_subject(message.subject_line) + is_expected.to have_body_text(message.title) + is_expected.to have_body_text(message.body_line1) + is_expected.to have_body_text(CGI.unescapeHTML(message.cta_link)) + is_expected.to have_body_text(CGI.unescapeHTML(message.cta2_link)) + is_expected.to have_body_text(cta_url) + is_expected.to have_body_text(cta2_url) + end + end + end end |