Module: MailerMacros

Defined in:
lib/generators/ab_admin/install/templates/spec/support/mailer_macros.rb

Instance Method Summary collapse

Instance Method Details

#deliveriesObject


14
15
16
# File 'lib/generators/ab_admin/install/templates/spec/support/mailer_macros.rb', line 14

def deliveries
  ActionMailer::Base.deliveries
end

#email_countObject


10
11
12
# File 'lib/generators/ab_admin/install/templates/spec/support/mailer_macros.rb', line 10

def email_count
  ActionMailer::Base.deliveries.size
end

#last_emailObject


2
3
4
# File 'lib/generators/ab_admin/install/templates/spec/support/mailer_macros.rb', line 2

def last_email
  ActionMailer::Base.deliveries.last
end

#reset_emailObject


6
7
8
# File 'lib/generators/ab_admin/install/templates/spec/support/mailer_macros.rb', line 6

def reset_email
  ActionMailer::Base.deliveries = []
end