-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
36 lines (21 loc) · 1.7 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
== Testing workflow
1. git clone git://github.com/gonzoyumo/resque_mailer_test.git
2. cd resque_mailer_test
3. open console and type : Notifier.deliver_password_reset_instructions
Looking in the resque-web, no more job processed, but development.log show me the mail just created (an I receive it if mail config is correct)
Note that it works well when using manual enqueue : Resque.enqueue(Notifier, :deliver_password_reset_instructions) Job is queued in the :mailer queue and successfully processed.
the resque_mailer method_missing seems not to be processed. The action_mailer method_missing take predecence over it and the mail is delivered immediatly.
Some more tests give me this clue :
calling a fake deliver_* method, it's catched by action_mailer :
Notifier.deliver_x
NoMethodError: undefined method `x' for #<Notifier:0x1030f3f58>
from /opt/local/lib/ruby/gems/1.8/gems/actionmailer-2.3.5/lib/action_mailer/base.rb:459:in `__send__'
from /opt/local/lib/ruby/gems/1.8/gems/actionmailer-2.3.5/lib/action_mailer/base.rb:459:in `create!'
from /opt/local/lib/ruby/gems/1.8/gems/actionmailer-2.3.5/lib/action_mailer/base.rb:452:in `initialize'
from /opt/local/lib/ruby/gems/1.8/gems/actionmailer-2.3.5/lib/action_mailer/base.rb:395:in `new'
from /opt/local/lib/ruby/gems/1.8/gems/actionmailer-2.3.5/lib/action_mailer/base.rb:395:in `method_missing'
calling a dummy method, it's catched by resque_mailer :
Notifier.not_a_deliver_method
NoMethodError: undefined method `not_a_deliver_method' for Notifier:Class
from /opt/local/lib/ruby/gems/1.8/gems/resque_mailer-0.2.1/lib/resque_mailer.rb:19:in `method_missing'
from /opt/local/lib/ruby/gems/1.8/gems/actionmailer-2.3.5/lib/action_mailer/base.rb:400:in `method_missing'