Sha256: 9f1c42aa2302af9e117f7d86317d77ff91fafbfef4d9fd8f8337ff4aa8c5219f
Contents?: true
Size: 856 Bytes
Versions: 1
Compression:
Stored size: 856 Bytes
Contents
require 'rails_helper' describe DecoratedMailer do include Jpmobile::Util before(:each) do ActionMailer::Base.deliveries = [] end shared_examples_for "content-type" do it "sends decorated mail successfully" do DecoratedMailer.deco_mail(@to).deliver email = ActionMailer::Base.deliveries.first email.header['Content-Type'].main_type.should == 'multipart' email.header['Content-Type'].sub_type.should == 'mixed' end end describe "docomo" do before(:each) do @to = "docomo@docomo.ne.jp" end it_behaves_like "content-type" end describe "au" do before(:each) do @to = "au@ezweb.ne.jp" end it_behaves_like "content-type" end describe "softbank" do before(:each) do @to = "softbank@softbank.ne.jp" end it_behaves_like "content-type" end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
jpmobile-4.1.1 | test/rails/overrides/spec/mailers/decorated_mailer_spec.rb |