class RSpec::Rails::Matchers::HaveEnqueuedMail
def mail_job_message(job)
def mail_job_message(job) job_args = deserialize_arguments(job) mailer_method = job_args[0..1].join('.') mailer_args = job_args[3..-1] msg_parts = [] msg_parts << "with #{mailer_args}" if mailer_args.any? msg_parts << "on queue #{job[:queue]}" if job[:queue] && job[:queue] != 'mailers' msg_parts << "at #{Time.at(job[:at])}" if job[:at] "#{mailer_method} #{msg_parts.join(', ')}".strip end