diff --git a/actionmailer/lib/action_mailer/delivery_methods.rb b/actionmailer/lib/action_mailer/delivery_methods.rb index d1467fb5261bc44e7dc417c7971f6ec4e0d09609..3b38dbccc763ef73154ccf77242a097b8941ce58 100644 --- a/actionmailer/lib/action_mailer/delivery_methods.rb +++ b/actionmailer/lib/action_mailer/delivery_methods.rb @@ -65,7 +65,7 @@ def wrap_delivery_behavior(mail, method=nil) #:nodoc: when NilClass raise "Delivery method cannot be nil" when Symbol - if klass = delivery_methods[method.to_sym] + if klass = delivery_methods[method] mail.delivery_method(klass, send(:"#{method}_settings")) else raise "Invalid delivery method #{method.inspect}" diff --git a/actionmailer/test/abstract_unit.rb b/actionmailer/test/abstract_unit.rb index 3a519253f978a76246c3771ceb4dd6f6c081dd82..487102b56482d161aea84d2def116140c76fa743 100644 --- a/actionmailer/test/abstract_unit.rb +++ b/actionmailer/test/abstract_unit.rb @@ -1,16 +1,4 @@ -# Pathname has a warning, so require it first while silencing -# warnings to shut it up. -# -# Also, in 1.9, Bundler creates warnings due to overriding -# Rubygems methods -begin - old, $VERBOSE = $VERBOSE, nil - require 'pathname' - require File.expand_path('../../../load_paths', __FILE__) -ensure - $VERBOSE = old -end - +require File.expand_path('../../../load_paths', __FILE__) require 'active_support/core_ext/kernel/reporting' # These are the normal settings that will be set up by Railties