Sha256: 7c353172f1e064a2b2a06b9c6a7d7889f60288d18bfa2d9fc041f9a87c3680eb
Contents?: true
Size: 525 Bytes
Versions: 9
Compression:
Stored size: 525 Bytes
Contents
require 'spec_helper' describe "Mailer", type: :request do before :each do @user = User.create name: 'Elmer', last_name: 'Fudd', address: '1234 Somewhere, Over NY 11111', email: 'elmer@fudd.com' end it "attaches an xlsx file" do visit "/users/#{@user.id}/send_instructions" last_email = ActionMailer::Base.deliveries.last expect(last_email.to).to eq([@user.email]) expect(last_email.attachments.first).to be expect(last_email.attachments.first.content_type).to match(/#{mime_type}/) end end
Version data entries
9 entries across 9 versions & 3 rubygems