aboutsummaryrefslogtreecommitdiffstats
path: root/spec/lib/mail_handler/mail_handler_spec.rb
diff options
context:
space:
mode:
authorLouise Crow <louise.crow@gmail.com>2014-12-03 09:22:41 +0000
committerLouise Crow <louise.crow@gmail.com>2014-12-03 09:22:41 +0000
commit7414ed478f212be2b48c95fafde15726b348b197 (patch)
tree1d89b90f604b837b097fb4274775c4f3b3a319d6 /spec/lib/mail_handler/mail_handler_spec.rb
parent479c9cd4567e2042d00c347f25a411373a6b1df9 (diff)
parentd05082c1cf1ddec789e547b54943f6e7d5bdffc1 (diff)
Merge branch 'release/0.20'0.20.0.0
Conflicts: config/general.yml-example
Diffstat (limited to 'spec/lib/mail_handler/mail_handler_spec.rb')
-rw-r--r--spec/lib/mail_handler/mail_handler_spec.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/lib/mail_handler/mail_handler_spec.rb b/spec/lib/mail_handler/mail_handler_spec.rb
index ffc40ced9..e7ad93300 100644
--- a/spec/lib/mail_handler/mail_handler_spec.rb
+++ b/spec/lib/mail_handler/mail_handler_spec.rb
@@ -346,6 +346,12 @@ describe 'when getting attachment attributes' do
attributes[0][:body].is_utf8?.should == true
end
+ it 'should get multiple attachments from a multipart mail with text and HTML alternatives, which should be UTF-8' do
+ mail = get_fixture_mail('apple-mail-with-attachments.email')
+ attributes = MailHandler.get_attachment_attributes(mail)
+ attributes.length.should == 7
+ end
+
it 'should expand a mail attached as text' do
# Note that this spec will only pass using Tmail in the timezone set as datetime headers
# are rendered out in the local time - using the Mail gem this is not necessary