aboutsummaryrefslogtreecommitdiffstats
path: root/spec/lib/mail_handler/backends
diff options
context:
space:
mode:
authorLouise Crow <louise.crow@gmail.com>2015-05-29 14:51:00 +0100
committerLouise Crow <louise.crow@gmail.com>2015-05-29 14:51:00 +0100
commit840fda9b310cde8bc72df1a93fdc47b1d817f552 (patch)
treeabef4b1adb27f38b172f2938d9537be4031dcc7f /spec/lib/mail_handler/backends
parentb7a40c15d8c69a02edfc68e2681b3f68228ce8f0 (diff)
parentd59a325de7cb43f114412a8ad62c60b331b8b19a (diff)
Merge branch 'hotfix/0.21.0.35' into rails-3-developrails-3-develop
Diffstat (limited to 'spec/lib/mail_handler/backends')
-rw-r--r--spec/lib/mail_handler/backends/mail_backend_spec.rb17
1 files changed, 17 insertions, 0 deletions
diff --git a/spec/lib/mail_handler/backends/mail_backend_spec.rb b/spec/lib/mail_handler/backends/mail_backend_spec.rb
index 044fbef4f..91d9e1b5a 100644
--- a/spec/lib/mail_handler/backends/mail_backend_spec.rb
+++ b/spec/lib/mail_handler/backends/mail_backend_spec.rb
@@ -151,4 +151,21 @@ DOC
end
+ describe :address_from_name_and_email do
+
+ it 'returns an address string' do
+ expected = 'Test User <test@example.com>'
+ address_from_name_and_email('Test User', 'test@example.com').should == expected
+ end
+
+ it 'does not change the name passed to it' do
+ original = "brønn"
+ name = original.dup
+ address_from_name_and_email(name, 'test@example.com')
+ name.should == original
+ end
+
+ end
+
+
end