From 2e588963bff5baf256cd2cdc0c8f615b12589edb Mon Sep 17 00:00:00 2001 From: Louise Crow Date: Wed, 19 Jun 2013 08:59:46 -0700 Subject: Allow the HTML display of the body of an email to handle the case where the body is only quoted text and there is no subject. --- spec/models/incoming_message_spec.rb | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'spec/models/incoming_message_spec.rb') diff --git a/spec/models/incoming_message_spec.rb b/spec/models/incoming_message_spec.rb index 03152f5ff..b06991a34 100644 --- a/spec/models/incoming_message_spec.rb +++ b/spec/models/incoming_message_spec.rb @@ -115,6 +115,16 @@ describe IncomingMessage, " when dealing with incoming mail" do end + it 'should handle a main body part that is just quoted content in an email that has + no subject' do + i = IncomingMessage.new + i.stub!(:get_main_body_text_unfolded).and_return("some quoting") + i.stub!(:get_main_body_text_folded).and_return("FOLDED_QUOTED_SECTION") + i.stub!(:subject).and_return(nil) + i.get_body_for_html_display + end + + end describe IncomingMessage, " display attachments" do -- cgit v1.2.3