Sha256: 30fae454783d156f542f7d6a3f1b894047b4931258985b4e219ada578dcc6471

Contents?: true

Size: 590 Bytes

Versions: 5

Compression:

Stored size: 590 Bytes

Contents

# encoding: utf-8
require 'spec_helper'

describe MailManager::Bounce do
  context "when checking pop account" do
    it "should not blow up when mail contains a bad extended char" do
      send_bounce('bad_utf8_chars.eml')
      MailManager::BounceJob.new.perform
    end
  end
  def send_bounce(filename)
    mail = Mail.new(File.readlines(File.expand_path(File.join(__FILE__,'..','..','..','support','files',filename))).join)
    mail.delivery_method ActionMailer::Base.delivery_method
    mail.delivery_method.settings.merge!(ActionMailer::Base.smtp_settings)
    mail.deliver
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
mail_manager-0.1.4 spec/test_app/spec/models/mail_manager/bounce_spec.rb
mail_manager-0.1.2 spec/test_app/spec/models/mail_manager/bounce_spec.rb
mail_manager-0.1.1 spec/test_app/spec/models/mail_manager/bounce_spec.rb
mail_manager-0.1.0 spec/test_app/spec/models/mail_manager/bounce_spec.rb
mail_manager-0.0.1 spec/test_app/spec/models/mail_manager/bounce_spec.rb