Commit Graph

413 Commits

Author SHA1 Message Date
José Valim
2d567e470a Add transfer_encoding= setter deprecation. 2010-01-30 16:39:27 +01:00
José Valim
17ea8d8d4d Automatically configure generators if application is defined. 2010-01-29 17:51:06 +01:00
José Valim
3f84091937 ActionMailer should depend just on AbstractController. 2010-01-29 17:51:05 +01:00
Mikel Lindsaar
2960077445 Add a failing test case for render :layout
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-01-29 17:51:05 +01:00
Mikel Lindsaar
1024c11f3c Added tests for rendering different template for new API
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-01-29 17:51:05 +01:00
Jeremy Kemper
452bb1e48d Rename 'defaults' class method to 'default' to reflect that it's a declaration 2010-01-27 19:38:17 -08:00
Jeremy Kemper
187b3b0b48 Fix time comparison. Mail#date returns DateTime not Time. 2010-01-27 19:08:36 -08:00
Jeremy Kemper
8c60acbea2 Expected attachment encoding is binary 2010-01-27 18:37:17 -08:00
Mikel Lindsaar
b6b3db6734 Fixed bug on HTML only emails getting set to text/plain 2010-01-28 00:24:30 +11:00
José Valim
9f63c4b26e Bring AM tests back to green again. 2010-01-26 19:50:59 +01:00
José Valim
af43674c1c Fix failing tests on AM about render(:body => Hash). 2010-01-26 19:15:32 +01:00
Joshua Peek
31b538df64 Failing AM test for legacy multipart alternative rendering 2010-01-26 09:37:20 -06:00
Joshua Peek
9f7190187c Failing AM test for nested layouts 2010-01-26 09:27:54 -06:00
José Valim and Mikel Lindsaar
05c4ad9d3f Tidy up tests and docs. 2010-01-26 16:00:24 +01:00
Mikel Lindsaar
ccea6ab07d Fixing up tests and docs to use defaults :from => 'name' instead of defaults({:from => 'name'}) 2010-01-27 00:38:12 +11:00
Mikel Lindsaar
21dcc20ed2 Fixed up documentation to reflect code change and cleaned up tests of spurious #deliver calls 2010-01-27 00:18:40 +11:00
Mikel Lindsaar
9520166f70 Fixed up being able to pass random headers in with headers, or mail. Also, undeprecated headers(hash) as this works now too 2010-01-27 00:06:19 +11:00
José Valim and Mikel Lindsaar
9dd65c368b Make defaults accept a hash. 2010-01-26 11:21:20 +01:00
Mikel Lindsaar
e297eed4f2 Fixing up expectations in base_test.rb 2010-01-26 17:11:36 +11:00
Mikel Lindsaar
0b05acd424 Implementing class level :defaults hash, instead of delivers_from et al 2010-01-26 17:08:55 +11:00
José Valim and Mikel Lindsaar
c02391f8f9 Fix small typo. 2010-01-26 01:54:23 +01:00
José Valim and Mikel Lindsaar
4af2bbc6b4 Merge branch 'master' of github.com:mikel/rails 2010-01-26 01:51:23 +01:00
José Valim and Mikel Lindsaar
74a5889abe Refactor content type setting, added tests to ensure boundary exists on multipart and fixed typo 2010-01-26 11:49:59 +11:00
José Valim and Mikel Lindsaar
6589976533 Remove old files, add some information to docs and improve test suite. 2010-01-26 01:43:41 +01:00
José Valim and Mikel Lindsaar
ace74974cf Got AM working with Mail yield on delivery_handler and updated tests 2010-01-25 21:47:03 +11:00
José Valim and Mikel Lindsaar
4240369a43 changed test to get TestMailer to use :file delivery method directly (as setup action was resetting delivery_method to :test on init 2010-01-25 13:46:44 +11:00
José Valim and Mikel Lindsaar
e4a989e9d9 Added delivery_handler method to mail and implemented in ActionMailer to deliver inside of instrumentation 2010-01-25 13:39:48 +11:00
José Valim and Mikel Lindsaar
e1c1318638 Added delivers_from. 2010-01-25 00:37:12 +01:00
José Valim and Mikel Lindsaar
48faf53be1 Add some view paths tests. 2010-01-25 00:20:38 +01:00
José Valim and Mikel Lindsaar
0ece244fee Ensure implicit multipart templates with locale works as expected. 2010-01-24 23:59:12 +01:00
José Valim and Mikel Lindsaar
a74a655648 Add tests to mail helper. 2010-01-24 19:52:50 +01:00
José Valim and Mikel Lindsaar
bd96614101 Move old tests to a specific folder and add some delivery method tests. 2010-01-24 19:36:42 +01:00
José Valim and Mikel Lindsaar
99f960a3d7 Handle some TODOs and deprecations. 2010-01-24 18:40:04 +01:00
José Valim and Mikel Lindsaar
0d931fecbb Finish cleaning up delivery methods implementation. 2010-01-24 18:11:57 +01:00
José Valim and Mikel Lindsaar
f30d73bab4 Add new class delivery method API. 2010-01-24 17:31:18 +01:00
José Valim and Mikel Lindsaar
73a9000402 Adding failing tests for calling just the action, instead of :create_action_name and :deliver_action_name 2010-01-24 20:38:53 +11:00
José Valim and Mikel Lindsaar
afc758297c Moving AS::Notifications call to one location in base 2010-01-24 12:30:13 +11:00
José Valim and Mikel Lindsaar
258ca14800 Delegated ActionMailer::Base.deliveries to Mail.deliveries, added callback support in Mail to call ActionMailer on delivery, moved deliver to deprecated API in preparation for new API 2010-01-24 11:15:42 +11:00
José Valim and Mikel Lindsaar
e7e4ed48df Set sort order for explicit parts from the collector's template sequence 2010-01-24 09:34:50 +11:00
José Valim and Mikel Lindsaar
c985a0ee3d Add some tests to collector with templates and any. 2010-01-23 12:46:40 +01:00
José Valim and Mikel Lindsaar
6ba944608e Make implicit and explicit templates pass through the same part creation process. 2010-01-23 12:20:20 +01:00
José Valim and Mikel Lindsaar
c6b16260fe Added basic explicit multipart rendering and tests 2010-01-23 21:37:34 +11:00
José Valim and Mikel Lindsaar
951397b4a2 Get implicit multipart and attachments working together. 2010-01-22 14:38:41 +01:00
José Valim and Mikel Lindsaar
1cd55928c6 First work on implicit multipart. 2010-01-22 13:56:06 +01:00
José Valim and Mikel Lindsaar
dcb9253693 Add basic template rendering to new DSL. 2010-01-22 13:27:26 +01:00
José Valim and Mikel Lindsaar
b30eb39ff0 Add more tests to new API. 2010-01-22 11:57:54 +01:00
José Valim and Mikel Lindsaar
343ac48f45 Moved deprecated_body.rb to deprecatead_api.rb 2010-01-22 11:01:21 +01:00
José Valim and Mikel Lindsaar
8a6a2ca712 Merge branch 'master' of git://github.com/rails/rails 2010-01-22 13:37:29 +11:00
José Valim and Mikel Lindsaar
77986f6bdb Added use of AS::Notifications for tmail_compat.rb 2010-01-22 12:49:13 +11:00
José Valim and Mikel Lindsaar
12c001fec4 Updating deprecated API to sanitize old style attachments hash to work with new mail.attachments method 2010-01-22 12:46:19 +11:00
José Valim
378464a2e4 Default to sync instrumentation. 2010-01-21 13:09:12 +01:00
José Valim and Mikel Lindsaar
3829f9ecfd Adding tests for attachments['blah.rb'] = {} et al 2010-01-21 20:03:55 +11:00
José Valim and Mikel Lindsaar
d3da87ce77 Mail method accepting all headers set via the hash 2010-01-21 00:10:22 +11:00
José Valim and Mikel Lindsaar
c34cfcc29f Created mail method for new API 2010-01-20 23:46:59 +11:00
José Valim and Mikel Lindsaar
10c509fbfa Moved old API into deprecated_api.rb in preparation for new Rails 3 Mailer API 2010-01-20 22:26:24 +11:00
Mikel Lindsaar
c04baed627 Fixing failing test on sendmail expectation 2010-01-20 14:12:17 +11:00
José Valim
e10f51b6b7 Refactor delivery methods. 2010-01-19 15:34:58 +01:00
José Valim
c1848f9736 Get all tests passing. 2010-01-19 14:28:04 +01:00
Mikel Lindsaar
d201d39437 latest updates 2010-01-19 23:09:46 +11:00
Mikel Lindsaar
2107921000 Merge branch 'master' of git://github.com/rails/rails into rails 2010-01-19 21:05:37 +11:00
José Valim
f00cbf7872 Bring render_message back for 2.3 compatibility. 2010-01-19 01:36:07 +01:00
José Valim
a0374582ff Bring body(Hash) behavior back. 2010-01-19 01:36:07 +01:00
Santiago Pastorino
8268d68b50 mail.create_path returns an array test fixed [#3712 status:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-01-17 14:54:06 +01:00
Mikel Lindsaar
ccb7d9def3 Fixing up base to refactor settings 2010-01-17 23:27:59 +11:00
Mikel Lindsaar
0750304c01 Migrated over to Mail doing delivery. 2010-01-16 14:02:55 +01:00
José Valim
704daad762 Ensure we just send Ruby Stdlib objects in ActionMailer notifications. 2010-01-15 12:24:31 +01:00
José Valim
2a6bc1263e Add subscriber to ActionMailer. 2010-01-14 01:07:03 +01:00
Mikel Lindsaar
1ddf17dff0 Return-Path per RFC needs '<' and '>' around the addr_spec 2010-01-08 12:17:12 +11:00
Jeremy Kemper
8087d51842 Liberalize picky test 2010-01-07 17:08:02 -08:00
Joshua Peek
ce56c36cd3 Autoload AM test case class 2010-01-04 16:22:46 -06:00
Mikel Lindsaar
bf6d0e2bc2 Updating to Mail 1.5.0, including default values for all Message#field_name methods, can access field objects by calling Message#[:field_name] 2010-01-02 22:39:00 -08:00
Mikel Lindsaar
a2880827b4 Adding :transfer_encoding -> :content_transfer_encoding as part of TmailCompat 2009-12-31 19:37:37 +11:00
Mikel Lindsaar
345e622a20 Adding TMailCompat layer for :set_content_type and friends 2009-12-30 16:12:51 +11:00
Jeremy Kemper
b27a3e8da3 Merge branch 'master' of git://github.com/mikel/rails into mail
Conflicts:
	actionmailer/lib/action_mailer.rb
2009-12-29 15:46:12 -08:00
Mikel Lindsaar
b354496bda Adding default 8bit encoding if the body has non usascii in it 2009-12-28 21:41:16 +11:00
Mikel Lindsaar
c039bcdb1c Moved sort_parts into Mail, updated mail requirement to 1.4.2 2009-12-28 12:25:14 +11:00
José Valim
4747a9a57e Getting rid of some warnings in AM suite. 2009-12-27 12:18:46 +01:00
José Valim
47e5caa96b Merge Mail with latest Rails and move mail gem to Gemfile. 2009-12-27 12:09:20 +01:00
Mikel Lindsaar
331d375cc3 Changing body to use :to_s instead of :decoded... better use case 2009-12-27 20:56:16 +11:00
Mikel Lindsaar
4e1fa4912d Updating actionmailer to call :to_s on all field values instead of decoded 2009-12-27 18:38:30 +11:00
José Valim
ee70d1b6ad adv_attr_accessors in ActionMailer are not sent to the views, use the mailer object if you need to access the subject, recipients, from, etc. 2009-12-25 21:35:40 +01:00
José Valim
4964d3b02c Make ActionMailer::Base inherit from AbstractController::Base
Signed-off-by: Yehuda Katz <wycats@Yehuda-Katz.local>
2009-12-22 11:29:06 -08:00
Mikel Lindsaar
63b124b043 Merged in latest changes from rails/master 2009-12-17 12:23:08 +11:00
Mikel Lindsaar
418639b4cf Fixes for working with 1.9.1-head 2009-12-17 12:00:32 +11:00
Mikel Lindsaar
186cd7bc53 Merge branch 'rails'
Conflicts:
	actionmailer/lib/action_mailer.rb
	actionmailer/lib/action_mailer/delivery_method/smtp.rb
2009-12-17 11:24:02 +11:00
Joshua Peek
7ee5843c3c Fully expand relative rails framework paths and make sure we aren't
adding any to the load path more than once.
2009-12-16 11:56:51 -06:00
Joshua Peek
6ac32a8328 Define a welcome controller in mailer tests 2009-11-29 18:28:45 -06:00
Michael Koziarski
7e0aa35c20 avoid generating invalid SMTP commands in ruby pre 1.9
Signed-off-by: Michael Koziarski <michael@koziarski.com>

Conflicts:

	actionmailer/lib/action_mailer/base.rb
2009-11-28 13:34:05 +13:00
Mikel Lindsaar
5f2395041d Merge branch 'master' of git://github.com/rails/rails into rails_master 2009-11-24 21:45:14 +11:00
Jeremy Kemper
671538cd6e Merge commit 'mikel/master' into mail
Conflicts:
	actionmailer/lib/action_mailer.rb
2009-11-23 15:29:35 -08:00
Mikel Lindsaar
906e308220 Fixed up incompatible encoding problem for Ruby 1.9 in test suite 2009-11-23 20:58:22 +11:00
Mikel Lindsaar
cc391c3022 Deprecating attachment :body => 'string' in favour of attachment :data => 'string' 2009-11-23 20:53:07 +11:00
Jeremy Kemper
d98fee67e2 Never require jcode 2009-11-22 15:41:29 -08:00
Jeremy Kemper
e68bc3f14e Merge commit 'origin/master' into mail 2009-11-22 10:31:47 -08:00
Mikel Lindsaar
747d56881a 131 tests, 309 assertions, 0 failures, 0 errors 2009-11-22 23:20:57 +11:00
Mikel Lindsaar
f6f70540bb Updating tests for Mail gem 2009-11-22 00:04:36 +11:00
Mikel Lindsaar
0e38f5bdcc 131 tests, 266 assertions, 9 failures, 6 errors 2009-11-21 23:55:53 +11:00
Mikel Lindsaar
6456a08334 Down to 13 failures, 14 errors 2009-11-20 22:01:40 +11:00
Mikel Lindsaar
a5e6295d72 Down to 30 failures total 2009-11-20 21:19:10 +11:00
Mikel Lindsaar
539d9b355f More updates... 45 errors left to get it working with Mail gem 2009-11-20 14:10:57 +11:00
Mikel Lindsaar
15d7cac282 Starting again on actionmailer integration with mail 2009-11-12 16:08:50 +11:00
Joshua Peek
11e798ae0f Avoid adding component lib/ to load path multiple times 2009-11-09 23:28:36 -06:00
José Valim
4a1f438781 Change mailer subjects lookup. 2009-11-09 10:57:53 -08:00
José Valim
2aafdc8396 Use I18n on ActionMailer subjects by default. 2009-11-01 02:23:49 +01:00
José Valim
e9667ad1f0 Make tests run without deprecation warning (just one left). 2009-11-01 02:23:48 +01:00
José Valim
418c3f801c Another refactoring on AM. body is deprecated, use render instead. 2009-11-01 02:23:48 +01:00
José Valim
43d5504f0a Move all render and layout pieces required in ActionMailer from ActionController to AbstractController. 2009-11-01 02:23:48 +01:00
José Valim
684c2dc208 Remove ActionMailer helpers and rely on AbstractController one. 2009-11-01 02:23:48 +01:00
Matthew Rudy Jacobs
f4f76772fb abstract all of the ActionMailer delivery methods into their own classes. thereby the following are equivalent
ActionMailer::Base.delivery_method = :smtp
  ActionMailer::Base.delivery_method = ActionMailer::DeliveryMethod::Smtp

we could equally set our own custom object
as long as it provides the instance method :perform_delivery(mail)

eg.

  class MySmsDeliveryMethod
    def perform_delivery(mail)
      Sms.send(mail['to'], mail['body'])
    end
  end

  MySmsMailer.delivery_method = MySmsDeliveryMethod.new

Signed-off-by: José Valim <jose.valim@gmail.com>
2009-11-01 02:23:47 +01:00
Yehuda Katz + Carl Lerche
4f6d6f7031 Have all the tests running off a single Gemfile 2009-10-20 16:34:44 -07:00
Joshua Peek
3ccaabc6c6 Need to use "use_controllers" for nonexistent controller in AM test 2009-10-18 10:39:21 -05:00
Yehuda Katz
e1490d4e4c Change config implementation in AV slightly 2009-10-15 14:41:59 -07:00
Jeremy Kemper
d5de94d6b7 Fix AM tests by configuring AV 2009-10-15 00:22:15 -07:00
Jeremy Kemper
4484f0bccf Don't push siblings on load path if using bundled env 2009-10-14 20:59:45 -07:00
Jeremy Kemper
6395c7bed2 Mark html safety 2009-10-09 18:36:58 -07:00
Pratik Naik
96b575d6dc Get rid of parenthesize argument warnings 2009-08-09 16:00:53 +01:00
Eric Davis
fbe6c3c195 Adds a :file delivery_method to save email to a file on disk
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#2438 state:committed]
2009-08-08 16:32:17 +12:00
Matt Duncan
5fdc33c1a3 Default sent_on time to now in ActionMailer
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#2607 state:committed]
2009-08-08 14:11:32 +12:00
Yehuda Katz
0612fd0f09 Replace _render_template_with_layout with _render_template since the layout is optional 2009-08-07 03:18:45 -03:00
Yehuda Katz + Carl Lerche
7583a24ee0 Move mocha down below initial T::U require and bump version to 0.9.7 [#2858 state:resolved] 2009-07-01 11:53:17 -07:00
Chad Woolley
5679bf64d5 Fix failing CI test (broken in 2daac47 or e693f45): make test_multipart_with_template_path_with_dots only test path with dots, and stop failing on unrelated mimetype assertion. The image/jpeg multipart content type is already tested in test_explicitly_multipart_messages.
Signed-off-by: Yehuda Katz <wycats@yehuda-katzs-macbookpro41.local>
2009-05-27 21:38:23 +02:00
Jeremy Kemper
df2d96a7f0 Move misplaced test 2009-05-22 15:32:35 -07:00
Yehuda Katz + Carl Lerche
ab83db9d06 Fixes ActionMailer to work with the ActionView refactoring 2009-04-27 12:34:25 -07:00
Yehuda Katz + Carl Lerche
0a132c2fe1 Refactor ActionView::Path
* Decouple from ActionController and ActionMailer
  * Bring back localization support.
  * Prepare to decouple templates from the filesystem.
  * Prepare to decouple localization from ActionView
  * Fix ActionMailer to take advantage of ActionView::Path
2009-04-22 17:24:41 -07:00
Carl Lerche & Yehuda Katz
906aebceed Bring abstract_controller up to date with rails/master
Resolved all the conflicts since 2.3.0 -> HEAD. Following is a list
of commits that could not be applied cleanly or are obviated with the
abstract_controller refactor. They all need to be revisited to ensure
that fixes made in 2.3 do not reappear in 3.0:

2259ecf368e6a6715966f69216e3ee86bf1a82a7
AR not available
  * This will be reimplemented with ActionORM or equivalent

06182ea02e92afad579998aa80144588e8865ac3
implicitly rendering a js response should not use the default layout
[#1844 state:resolved]
  * This will be handled generically

893e9eb99504705419ad6edac14d00e71cef5f12
Improve view rendering performance in development mode and reinstate
template recompiling in production [#1909 state:resolved]
  * We will need to reimplement rails-dev-boost on top of the refactor;
    the changes here are very implementation specific and cannot be
    cleanly applied. The following commits are implicated:

      199e750d46c04970b5e7684998d09405648ecbd4
      3942cb406e1d5db0ac00e03153809cc8dc4cc4db
      f8ea9f85d4f1e3e6f3b5d895bef6b013aa4b0690
      e3b166aab37ddc2fbab030b146eb61713b91bf55
      ae9f258e03c9fd5088da12c1c6cd216cc89a01f7
      44423126c6f6133a1d9cf1d0832b527e8711d40f

0cb020b4d6d838025859bd60fb8151c8e21b8e84
workaround for picking layouts based on wrong view_paths
[#1974 state:resolved]
  * The specifics of this commit no longer apply. Since it is a two-line
    commit, we will reimplement this change.

8c5cc66a831aadb159f3daaffa4208064c30af0e
make action_controller/layouts pick templates from the current instance's
view_paths instead of the class view_paths [#1974 state:resolved]
  * This does not apply at all. It should be trivial to apply the feature
    to the reimplemented ActionController::Base.

87e8b162463f13bd50d27398f020769460a770e3
fix HTML fallback for explicit templates [#2052 state:resolved]
  * There were a number of patches related to this that simply compounded
    each other. Basically none of them apply cleanly, and the underlying
    issue needs to be revisited. After discussing the underlying problem
    with Koz, we will defer these fixes for further discussion.
2009-04-13 15:18:45 -07:00
Sean Dague
1dff106888 Allow custom type for multipart emails [#1691 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-03-10 16:38:37 +00:00
Jeremy Kemper
1c36172c13 Ruby 1.9 compat: rename deprecated assert_raises to assert_raise.
[#1617 state:resolved]
2009-03-08 13:11:58 -07:00
Elliott Wood
c41ed929bb Removed the "charset" parameter from the Content-Type header of multipart sections of nested multipart messages.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#2109 state:committed]
2009-03-02 18:51:30 +13:00
thedarkone
6bf9b69bde Fix a failing mailer test. 2009-02-20 12:08:05 -06:00
thedarkone
3942cb406e Port fast reloadable templates from rails-dev-boost. 2009-02-12 13:04:12 -06:00
Matt Jones
250dfb18af Fixed that ActionMailer should send correctly formatted Return-Path in MAIL FROM for SMTP [#1842 state:committed]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2009-02-05 20:53:02 +01:00
Jeremy Kemper
b302e023b7 Require rubygems 2009-02-03 18:58:06 -08:00
Jeremy Kemper
278186534c Bump mocha requirement for Ruby 1.9 compat. Remove uses_mocha. 2009-02-03 18:40:22 -08:00
Yehuda Katz
eb9af20b7c Begin unifying the interface between ActionController and ActionView 2009-01-22 16:18:10 -06:00
Jose' Valim
c2e7851fb2 Add ActionMailer::Base#enable_starttls_auto option for enabling/disabling STARTTLS. [#1731 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-01-18 04:19:18 +00:00
Mike Gunderloy
1e02d95d60 Make ActioMailer quoting test play nice with Ruby 1.9 [#1726 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-01-16 17:25:37 +00:00
Joshua Peek
558ab327b7 Clean up view path cruft and split path implementations into Template::Path and Template::EagerPath 2008-12-29 19:27:19 -06:00
Joshua Peek
858a420ce1 Ensure the template format is always passed to the template finder. Now we can cleanup some nasty stuff. 2008-12-21 17:24:16 -06:00
Jeremy Kemper
781e29be0a Fix tests broken by switch to Pathname 2008-12-09 11:39:45 -08:00
Joshua Peek
7c0dfa35db Register bogus template handlers for ActionMailer test fixtures 2008-12-03 13:58:47 -06:00
Tekin Suleyman
dab78e55cf Ensure ActionMailer doesn't blow up when a two argument proc is set for the asset host
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#1394 state:committed]
2008-12-01 19:38:25 +01:00
Jeremy Kemper
6d91e7a7d6 Remove explicit tmail requires in favor of autoload 2008-11-23 13:16:39 -08:00
Colin Curtin
1d4554d766 ActionMailer should respect content type when choosing layouts
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2008-11-21 04:09:14 +05:30
Alexey Mahotkin
84583657f4 Fixed RFC-2045 quoted-printable bug [#1421 state:committed]
http://www.faqs.org/rfcs/rfc2045.html says:

          may be
          represented by an "=" followed by a two digit
          hexadecimal representation of the octet's value.  The
          digits of the hexadecimal alphabet, for this purpose,
          are "0123456789ABCDEF".  Uppercase letters must be
          used; lowercase letters are not allowed.

ActionMailer, however, used "=%02x" specification.

Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-11-20 23:10:15 +01:00
Jeremy Kemper
eeea1a26ec Merge branch 'master' into testing 2008-11-15 12:21:04 -08:00
David Heinemeier Hansson
e6b33a8337 Added lambda merging to OptionMerger (especially useful with named_scope and with_options) [#740 state:commited] (Paweł Kondzior) 2008-11-15 16:44:47 +01:00
Joel Chippindale
c65075feb6 Fixed method_missing for ActionMailer so it no longer matches methods where deliver or create are not a suffix [#1318 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2008-11-11 09:46:29 -06:00
Joel Chippindale
a62e9e90d8 Fix for ActionMailer::Base.method_missing so that it raises NoMethodError when no method is found [#1330 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2008-11-11 09:46:29 -06:00
Jeremy Kemper
17ac2a2482 Ruby 1.9 compat: check for minitest's assertion also 2008-11-08 22:49:28 -05:00
Grant Hollingworth
732c724df6 Turn on STARTTLS if it is available in Net::SMTP (added in Ruby 1.8.7) and the SMTP server supports it [#1336 state:committed]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-11-06 13:07:16 +01:00
madlep
2def5b6314 Fixed load path for actionmailer and activesupport tests to always load from local lib files.
[#983 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-10-04 07:57:18 -07:00
Joshua Peek
28bf2fa038 Protect body ivar from being clobbered by the mailer template assigns 2008-09-28 12:31:45 -05:00
U-ESCAPEE\Mack
f3f7d166d8 Fixed problem causes by leftover backup templates ending in tilde [state:committed #969]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-09-09 23:29:29 -05:00
David Heinemeier Hansson
6228220c9b Revert "Revert "Add layout functionality to mailers.""
This reverts commit 36c6aa01ee0a7aee5b0510a8e649c44de318b060.
2008-09-09 17:25:09 -05:00
David Heinemeier Hansson
36c6aa01ee Revert "Add layout functionality to mailers."
This reverts commit e9a8e0053be3b293ab89fb584f1d660063f107aa.
2008-09-09 17:20:55 -05:00
Pratik Naik
e9a8e0053b Add layout functionality to mailers.
Mailer layouts behaves just like controller layouts, except layout names need to
have '_mailer' postfix for them to be automatically picked up.
2008-08-31 19:17:42 +01:00
James Mead
3cf773b187 ActionMailer should respond_to? to methods handled by method_missing [#700 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2008-08-29 15:09:47 -05:00
Joshua Peek
c0dd0cee46 Removed old deprecation test because the warning was removed in 1129a24 2008-08-22 13:43:34 -05:00
Joshua Peek
04248c6208 Ensure templates are rendered if all the parts are already processed 2008-08-13 19:04:56 -05:00
Joshua Peek
b2504f8ba0 Tidy up ActionMailer rendering logic to take advantage of view path cache instead of using file system lookups 2008-08-06 20:11:21 -05:00
Tarmo Tänav
656f0e7c6c Fix file permissions
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2008-07-31 16:36:23 -05:00
Joshua Peek
e23156e87b Only create a path for ActionMailer template root instead of a path set. Better fix than 7461227 2008-07-19 12:35:42 -05:00
Joshua Peek
b74b97fef5 Update uses_mocha in ActionMailer and ActiveResource 2008-07-19 11:14:12 -05:00
Joshua Peek
7d5c447d9c Stubba is included in Mocha already 2008-07-11 11:12:53 -05:00
Joshua Peek
bec4b69a3b Replaced TemplateFinder abstraction with ViewLoadPaths 2008-06-17 21:21:07 -05:00
Adam
cf6299dbd7 Add ActionMailer#reply_to. [#245 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2008-05-29 10:38:00 +01:00
Jeremy Kemper
940cf0cacd Bah, don't test TMail in AM
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@9219 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-04-03 18:32:10 +00:00
Jeremy Kemper
5c17a74d59 Ruby 1.9 compat: compare with same encoding
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@9218 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-04-03 17:28:05 +00:00
Jeremy Kemper
767be30e61 force_encoding to ascii-8bit instead of nil
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@9184 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-04-01 05:32:11 +00:00
Jeremy Kemper
af74077544 Ruby 1.9 compat: mark utf-8 encoding.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@9165 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-03-31 05:31:37 +00:00
Jeremy Kemper
218417b8a9 Remove empty .rhtml templates
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8820 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-02-07 23:10:01 +00:00
Jeremy Kemper
fbd3eb7142 Less verbose mail logging: just recipients for :info log level; the whole email for :debug only. Closes #8000.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8781 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-02-02 05:32:15 +00:00
Jeremy Kemper
abfab89fd8 Ruby 1.9 compat: test encoding fixes. Closes #10597 [murphy]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8666 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-19 03:03:38 +00:00
Rick Olson
2dda639120 Updated TMail to version 1.2.1 [raasdnil]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8620 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-11 01:55:20 +00:00
Jeremy Kemper
139b92495f * Continue evolution toward ActiveSupport::TestCase and friends. #10679 [Josh Peek]
* TestCase: introduce declared setup and teardown callbacks. Pass a list of methods and an optional block to call before setup or after teardown. Setup callbacks are run in the order declared; teardown callbacks are run in reverse.  [Jeremy Kemper]


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8570 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-05 13:34:15 +00:00
Jeremy Kemper
1ad87adc9f require abstract_unit directly since test is in load path
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8565 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-05 13:32:22 +00:00
David Heinemeier Hansson
6a6367d7d2 Fixed that you don't have to call super in ActionMailer::TestCase#setup (closes #10406) [jamesgolick]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8536 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-03 00:40:28 +00:00
Michael Koziarski
f1047173e8 Remove old tests which relied on @ being an ATOM to work around old Mail.app bugs. Closes #10317 [mikel]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8257 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-12-02 20:31:39 +00:00
Michael Koziarski
1d32cec17d Allow body to be specified for nested parts with action mailer. Closes #10271 [redinger]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8238 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-11-29 02:52:49 +00:00
Rick Olson
bd5ed65110 Update ActionMailer so it treats ActionView the same way that ActionController does. Closes #10244 [rick]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8212 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-11-26 03:36:28 +00:00
Michael Koziarski
e0ce691187 Add missing sub template fixtures. References #10130 [java]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8188 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-11-22 05:01:43 +00:00
David Heinemeier Hansson
a76490d917 Fixed that partial rendering should look at the type of the first render to determine its own type if no other clues are available (like when using text.plain.erb as the extension in AM) (closes #10130) [java] Fixed that partials would be broken when using text.plain.erb as the extension #10130 [java]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8166 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-11-18 22:01:33 +00:00
David Heinemeier Hansson
57cde63138 Allow ActionMailer subclasses to individually set their delivery method (so two subclasses can have different delivery methods) (closes #10033) [zdennis]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8111 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-11-07 16:05:17 +00:00
Rick Olson
2a51c8682d Update TMail to v1.1.0. Use an updated version of TMail if available. [mikel]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8084 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-11-06 14:24:32 +00:00
Michael Koziarski
2283524dff Test which fails without [8052] [Koz]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8053 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-10-29 04:13:51 +00:00
Michael Koziarski
2cc0cac3ef Introduce TestCase subclasses for testing rails applications allowing tests to be DRY'd up a bit and to provide a path toward tidying up our monkeypatching of test/unit.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8022 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-10-26 02:21:21 +00:00
Jeremy Kemper
faa455a435 Missed mailer adds.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7929 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-10-16 05:05:03 +00:00
Jeremy Kemper
cf2ee1451b Fix silent failure of rxml templates. Closes #9879.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7921 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-10-15 20:30:48 +00:00
Tobias Lütke
19c9c7fafb Set default charset of MTAs to ISO instead of us-ascii (unless reported otherwise)
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7819 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-10-09 13:34:51 +00:00
Michael Koziarski
7573791284 Disable the routing optimisation code when dealing with foo_url helpers. Add test to actionmailer to expose the problem they introduced. References #9450 [Koz]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7572 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-09-22 19:20:06 +00:00
David Heinemeier Hansson
6ccf503229 Test requirement fix (closes #9276) [lazyatom]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7547 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-09-22 17:37:39 +00:00
David Heinemeier Hansson
6203d4574c Improved test coverage (closes #7571) [joost]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7545 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-09-22 17:32:39 +00:00
Jeremy Kemper
12f8f89307 Fix attachment decoding when using the TMail C extension. Closes #7861.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7476 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-09-14 05:30:52 +00:00
Jeremy Kemper
e963354124 Increase mail delivery test coverage. Closes #8692.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7070 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-06-20 06:50:43 +00:00
Jeremy Kemper
cd9d1711da Missed svn adds. References #7534.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6969 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-06-08 04:40:12 +00:00
Jeremy Kemper
271404e8b9 Register alternative template engines using ActionMailer::Base.register_template_extension('haml'). Closes #7534.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6962 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-06-07 23:42:47 +00:00
Jamis Buck
f9a4774e0e Make sure parsed emails recognize attachments nested in multpart parts (closes #6714)
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6207 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-02-22 19:04:00 +00:00
Jamis Buck
b6923c2b29 Fix broken tests
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6206 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-02-22 19:02:14 +00:00
David Heinemeier Hansson
21187c0fb4 Apply the rest of Chads patch
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6180 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-02-21 00:29:44 +00:00
Michael Koziarski
704f2cc6de Improve Test Coverage for raise_delivery_errors. [kevinclark] closes #7152
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6006 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-01-21 23:20:44 +00:00