Module: Aws::Rails::ActionMailbox::RSpec
- Defined in:
- lib/aws/rails/action_mailbox/rspec.rb,
lib/aws/rails/action_mailbox/rspec/email.rb,
lib/aws/rails/action_mailbox/rspec/subscription_confirmation.rb
Overview
it ‘delivers an email notification’ do
action_mailbox_ses_deliver_email(mail: Mail.new(to: '[email protected]'))
expect(ActionMailbox::InboundEmail.last.mail.recipients).to eql ['[email protected]']
end
end
Defined Under Namespace
Classes: Email, SubscriptionConfirmation
Instance Method Summary collapse
- #action_mailbox_ses_deliver_email(options = {}) ⇒ Object
- #action_mailbox_ses_deliver_subscription_confirmation(options = {}) ⇒ Object
Instance Method Details
#action_mailbox_ses_deliver_email(options = {}) ⇒ Object
40 41 42 43 44 45 46 47 48 |
# File 'lib/aws/rails/action_mailbox/rspec.rb', line 40 def action_mailbox_ses_deliver_email( = {}) email = Email.new(**) (email) post email.url, params: email.params, headers: email.headers, as: :json end |
#action_mailbox_ses_deliver_subscription_confirmation(options = {}) ⇒ Object
29 30 31 32 33 34 35 36 37 38 |
# File 'lib/aws/rails/action_mailbox/rspec.rb', line 29 def action_mailbox_ses_deliver_subscription_confirmation( = {}) subscription_confirmation = SubscriptionConfirmation.new(**) (subscription_confirmation) stub_aws_sns_subscription_request post subscription_confirmation.url, params: subscription_confirmation.params, headers: subscription_confirmation.headers, as: :json end |