Commit ff659b9d36ba7b72d330735b10f1726e8608e0e3

Authored by Nathan Broadbent
1 parent d59c7bb7
Exists in master and in 1 other branch production

Inline CSS is now an ActionMailer interceptor, which I'm not sure how to test. M…

…ailer class is loaded too early in spec run, and so the InlineCSSHelpers aren't included on ActionMailer::Base at that time.
Showing 1 changed file with 1 additions and 5 deletions   Show diff stats
spec/mailers/mailer_spec.rb
@@ -4,6 +4,7 @@ describe Mailer do @@ -4,6 +4,7 @@ describe Mailer do
4 context "Err Notification" do 4 context "Err Notification" do
5 include EmailSpec::Helpers 5 include EmailSpec::Helpers
6 include EmailSpec::Matchers 6 include EmailSpec::Matchers
  7 + Mailer.send :helper, ActionMailer::InlineCssHelper
7 8
8 before do 9 before do
9 @notice = Factory(:notice, :message => "class < ActionController::Base") 10 @notice = Factory(:notice, :message => "class < ActionController::Base")
@@ -13,11 +14,6 @@ describe Mailer do @@ -13,11 +14,6 @@ describe Mailer do
13 it "should html-escape the notice's message for the html part" do 14 it "should html-escape the notice's message for the html part" do
14 @email.should have_body_text("class &lt; ActionController::Base") 15 @email.should have_body_text("class &lt; ActionController::Base")
15 end 16 end
16 -  
17 - it "should inline css" do  
18 - @email.should have_body_text '<td class="header" style="'  
19 - # ('style' attribute is not present unless premailer works.)  
20 - end  
21 end 17 end
22 end 18 end
23 19